ObjFW  Diff

Differences From Artifact [fb3d19ec1b]:

To Artifact [bb64dfc30f]:


29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
{
	if ((self = [super init])) {
		if (str == NULL) {
			length = 0;
			string = NULL;
		} else {
			length = strlen(str);
			if ((string = [self getMem: length + 1]) == NULL)
				return NULL;
			memcpy(string, str, length + 1);
		}
	}
	return self;
}

- (char*)cString







|
<







29
30
31
32
33
34
35
36

37
38
39
40
41
42
43
{
	if ((self = [super init])) {
		if (str == NULL) {
			length = 0;
			string = NULL;
		} else {
			length = strlen(str);
			string = [self getMem: length + 1];

			memcpy(string, str, length + 1);
		}
	}
	return self;
}

- (char*)cString