([MemoryStream -readLine]): Don't use +stringWithCStringNoCopy:.

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@1946 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
mccallum 1996-11-24 18:27:01 +00:00
parent 7202be0561
commit 898ed24d5f

View file

@ -194,7 +194,10 @@ static BOOL debug_memory_stream = NO;
ret[len] = '\0';
position += len+1;
}
return [NSString stringWithCStringNoCopy:ret];
return [[[NSString alloc] initWithCStringNoCopy: ret
length: strlen (ret)
freeWhenDone: YES]
autorelease];
}
/* Making these nested functions (which is what I'd like to do) is