• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
NSMutable Data Crash
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSMutable Data Crash


  • Subject: NSMutable Data Crash
  • From: Aalok <email@hidden>
  • Date: Mon, 3 Jul 2006 20:12:13 +0530

Hi,

I have a unique problem. I have written a piece of code which runs
perfectly fine on my machines.(ppc and intel) But when shipped, the
program crashes!!

What I figured out is the program crashes after the line
NSLog(@"**********Here 1**********"); in the code below.

The only line in between the next log is [playlistMetaDataArray
addObject:playlistHeaderList1];

I have initialized playlistMetaDataArray as  NSMutableArray but
somehow it throws runtime error. (is that something to do with
"retain"??)

Please help to slove.

-(void)makeList1:(NSDictionary*)playlistMap
playlistDetails:(NSDictionary*)detailMap
{
	NSLog(@"**********Entered makeList1**********");
	Byte byteL='L';
	Byte byteN='N';

	NSMutableData *list1 = [[NSMutableData alloc] initWithCapacity:25];
	playlistHeaderList1 = [[NSMutableData alloc] initWithCapacity:25];

	playlistMetaDataArray = [[NSMutableArray alloc] init];
	finalList1 = [[NSMutableData alloc] init];

	unsigned int listCount1;
	unsigned int listCount2;

	NSString* beoFile=[FAVORITES stringByAppendingString:@".abc"];

	NSString* beoFilePathOn=[[NSString alloc] initWithString:volume];
	beoFilePathOn=[[[beoFilePathOnBM1 stringByAppendingString:sharedFolder]
														stringByAppendingString:systemFolderIn]
														stringByAppendingString:beoFile];

	if(![fileManager fileExistsAtPath:Path])
	{
		NSLog(@"**********beo file doesn't exists**********");
		//Create the file
		[self generateMetaDataFile:beoFile
								GUID:UUID
								command:NET_MUSIC_FAVORITES
								msgKind:@"1"];
		NSLog(@"**********net music file created. file created**********");
		//Read the header contents
		[playlistHeaderList1 initWithContentsOfFile:[tempFileLocation
stringByAppendingString:beoFile]];
		NSLog(@"**********Here 1**********");
		[playlistMetaDataArray addObject:playlistHeaderList1];
		NSLog(@"**********Here 2**********");
		NSArray *allKeys=[NSArray arrayWithArray:[playlistMap allKeys]];
		NSLog(@"**********header list read**********");

regards,
aalok
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: NSMutable Data Crash
      • From: Bill Bumgarner <email@hidden>
  • Prev by Date: Re: flipping between tabs in tab view
  • Next by Date: Re: flipping between tabs in tab view
  • Previous by thread: Re: flipping between tabs in tab view
  • Next by thread: Re: NSMutable Data Crash
  • Index(es):
    • Date
    • Thread