1.1 --- a/templates/native/common.c Sun Feb 12 23:24:42 2017 +0100
1.2 +++ b/templates/native/common.c Mon Feb 13 18:54:59 2017 +0100
1.3 @@ -34,11 +34,12 @@
1.4 return attr;
1.5 }
1.6
1.7 -__attr __new_str(char *s)
1.8 +__attr __new_str(char *s, int size)
1.9 {
1.10 - /* Create a new string and mutate the __data__ and __key__ attributes. */
1.11 + /* Create a new string and mutate the __data__, __size__ and __key__ attributes. */
1.12 __attr attr = __NEWINSTANCE(__builtins___str_string);
1.13 attr.value->attrs[__pos___data__].strvalue = s;
1.14 + attr.value->attrs[__pos___size__].intvalue = size;
1.15 attr.value->attrs[__pos___key__] = __NULL;
1.16 return attr;
1.17 }