• 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
Re: EXC_BAD_ACCESS when trying to use [NSMutableURLRequest setHTTPBodyStream]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: EXC_BAD_ACCESS when trying to use [NSMutableURLRequest setHTTPBodyStream]


  • Subject: Re: EXC_BAD_ACCESS when trying to use [NSMutableURLRequest setHTTPBodyStream]
  • From: Dave Carrigan <email@hidden>
  • Date: Thu, 10 Jan 2008 09:29:14 -0800


On Jan 10, 2008, at 8:52 AM, I. Savant wrote:

I've had this suggestion from a few people, so I'm going to report
back to the list that the unretained objects is not the cause of my
problem. I changed my code to look like:

Is the "Uploader" object that contains this code retained as well? You set it as the delegate of your NSURLConnection. Is it still around when the NSURLConnection instance you create makes calls back to your Uploader instance?

Yes it is, because it's not autorelease. It's alloced with [[Uploader alloc] initWithURL] and I never do a dealloc on it. (But just to be sure, I just added a retain there, with no change in the crash.)


The error you're reporting *is* memory-management-related.

Yes, that seems reasonable, but the more I think about it, the more I think it must be a bug in the library. Based on the stack trace, it seems like it's a problem with the NSInputStream object, but I even tried doing


NSInputStream* stream = [[[NSInputStream ....] retain] retain] retain]

to try and workaround it if something is doing an extra release, but I still get the same crash.

--
Dave Carrigan
email@hidden
Seattle, WA, USA

Attachment: PGP.sig
Description: This is a digitally signed message part

_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: EXC_BAD_ACCESS when trying to use [NSMutableURLRequest setHTTPBodyStream]
      • From: "I. Savant" <email@hidden>
    • Re: EXC_BAD_ACCESS when trying to use [NSMutableURLRequest setHTTPBodyStream]
      • From: j o a r <email@hidden>
References: 
 >EXC_BAD_ACCESS when trying to use [NSMutableURLRequest setHTTPBodyStream] (From: Dave Carrigan <email@hidden>)
 >Re: EXC_BAD_ACCESS when trying to use [NSMutableURLRequest setHTTPBodyStream] (From: Dave Carrigan <email@hidden>)
 >Re: EXC_BAD_ACCESS when trying to use [NSMutableURLRequest setHTTPBodyStream] (From: "I. Savant" <email@hidden>)

  • Prev by Date: Re: NSMutableAttributedString binding
  • Next by Date: Re: Setting spell-checker underlines
  • Previous by thread: Re: EXC_BAD_ACCESS when trying to use [NSMutableURLRequest setHTTPBodyStream]
  • Next by thread: Re: EXC_BAD_ACCESS when trying to use [NSMutableURLRequest setHTTPBodyStream]
  • Index(es):
    • Date
    • Thread