file - Different behaviour of [NSMutableString writeToFile] in iOS7 and iOS8 -
here have demo code saving nsmutablestring in file (filename.dat)
nserror* error = nil; nsmutablestring* dat = [[nsmutablestring alloc] initwithcapacity:1]; bool result = [dat writetofile:@"filename.dat" atomically:yes encoding:nsutf8stringencoding error:&error]; but have 2 different output while rung in ios7 , ios8beta5
output xcode5+ios7 
output xcode5+ios8 
while
running in ios7 shows there in error in parsing file path, in ios8beta5 it crash saying [nsfilemanager filesystemrepresentationwithpath:] have nil or empty path. question :
in both sdk ios8 , ios7 take nserror argument return error, believe should return error instead of crashing application
apple mansion changes regarding it, if yes please give me reference link same.
the path pass [nsdata writetofile:atomically:] not complete , should full path.
that done getting path documents folder , appending filename.
Comments
Post a Comment