Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 637811
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 13, 20262026-05-13T20:39:52+00:00 2026-05-13T20:39:52+00:00

I had a EXC_BAD_ACCESS message in my console. I read about the environment variables

  • 0

I had a EXC_BAD_ACCESS message in my console. I read about the environment variables NSZombieEnabled and MallocStackLoggingNoCompact on this site. I created my environment variables: NSZombieEnabled = YES and MallocStackLoggingNoCompact = 1. In the console, I saw

2010-03-01 19:13:46.924
CruzNomad[7952:207] *** -[CFString
stringByAddingPercentEscapesUsingEncoding:]:
message sent to deallocated instance
0x58448e0

Then at the (gdb) prompt, I did info malloc-history 0x58448e0, which gave me:

Alloc: Block address: 0x058448e0 length: 64
Stack - pthread: 0xa0b33500 number of frames: 25
    0: 0x98e089bc in malloc_zone_malloc
    1: 0x21516aa in _CFRuntimeCreateInstance
    2: 0x2152bf8 in __CFStringCreateImmutableFunnel3
    3: 0x21567d9 in CFStringCreateCopy
    4: 0x21742fc in _CFStringCreateWithFormatAndArgumentsAux
    5: 0xdb546 in -[NSPlaceholderString initWithFormat:locale:arguments:]
    6: 0xdb4d8 in +[NSString stringWithFormat:]
    7: 0x23aa3 in -[BuisnessCardViewController viewDidLoad] at /Users/.../Classes/BuisnessCardViewController.m:85
    8: 0x3d6796 in -[UIViewController view]
    9: 0x347b4 in -[gm_menuViewController btn5_Pressed:] at /Users/.../Classes/menuViewController.m:535
   10: 0x357459 in -[UIApplication sendAction:to:from:forEvent:]
   11: 0x3baba2 in -[UIControl sendAction:to:forEvent:]
   12: 0x3bcdc3 in -[UIControl(Internal) _sendActionsForEvents:withEvent:]
   13: 0x3bbb0f in -[UIControl touchesEnded:withEvent:]
   14: 0x370e33 in -[UIWindow _sendTouchesForEvent:]
   15: 0x35a81c in -[UIApplication sendEvent:]
   16: 0x3610b5 in _UIApplicationHandleEvent
   17: 0x2984ed1 in PurpleEventCallback
   18: 0x2197b80 in CFRunLoopRunSpecific
   19: 0x2196c48 in CFRunLoopRunInMode
   20: 0x298378d in GSEventRunModal
   21: 0x2983852 in GSEventRun
   22: 0x362003 in UIApplicationMain
   23: 0x2c8c in main at /Users/.../source/main.m:14
   24: 0x2bfa in start

Line 7 says the problem was in line 85 of BuisnessCardViewController.m. That line is here:

fullAddress = [NSString stringWithFormat:@"%@ %@", fullAddress, myString];

I’m appending the contents of fullAddress and myString and storing it back in fullAddress.

If I’m interpreting this correctly, it appears that after this line, fullAddress is deallocated. When I drop a breakpoint and hover over the variable, its value says “out of scope.”

fullAddress works later in this method. I use it to send to send to Google for reverse geocoding in line 164 of the same method.

NSString    *urlString = [NSString stringWithFormat:@"http://maps.google.com/maps/geo?q=%@&output=csv", [fullAddress stringByAddingPercentEscapesUsingEncoding:NSUTF8StringEncoding]];

Even here, it says “out of scope.” I’m stumped…any advice??

Thanks!

Thomas

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-13T20:39:52+00:00Added an answer on May 13, 2026 at 8:39 pm

    In most cases this happens when you don’t retain an attribute which is object and send late messages to it in other methods, late.

    So, where some strings are initialized try:

    [fullAddress retain];
    

    or

    [myString retain];
    

    depending which one is initialized in other method.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Had a good read through similar topics but I can't quite a) find one
Had this working; at one stage. The problem is the following text is now
I had a debate about macros and their readability. I think that in some
I am new to cocos2d and suddenly got this EXC_BAD_ACCESS, I made a new
I thought I had this sorted, but I am still missing something. Very simply,
I'm migrating a webapp to python 2.7 with GAE and this error message appears:
Had a quick google to see if this can be done without much luck,
I'm having problem with FS controller page template. I had this Plone2 base product
My newness to xcode has had me scratching my head over this problem for
Had a quick question about joins in mysql and indexing. If I had 2

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.