[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

using NSKeyedArchiver ...

From: Paddy Smith
Subject: using NSKeyedArchiver ...
Date: Wed, 27 Dec 2006 14:41:56 +0000

the following code 'seems to work' on macosx, but not on the gnustep
in debian etch.
Am I doing something silly ?

int main (int argc, const char * argv[]) {
       NSAutoreleasePool * pool = [[NSAutoreleasePool alloc] init];

       NSMutableString *foo;
       foo=[[NSMutableString alloc] init];
       [foo setString: @"wib"];
       NSLog(@"check: %08x: %@", foo, foo);

       NSData *bar;
       bar=[NSKeyedArchiver archivedDataWithRootObject:foo];

       NSMutableString *baz;
       baz=[NSKeyedUnarchiver unarchiveObjectWithData:bar];
       NSLog(@"check: %08x: %@", baz, baz);

       [pool release];
       return 0;


reply via email to

[Prev in Thread] Current Thread [Next in Thread]