Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: String problem



tony cate wrote:
| The ISA is changing. I can't tell where. Is there a way to watch an
| object in debug and break if it is modified?

Usually, that means that the object has been deallocated, and its storage reused to hold some other object. (It could also mean that you've got an invalid pointer somewhere and you're overwriting the object storage from some unexpected place in your code. Were it my bug, I'd look for one too many releases, or releasing something that's also autoreleased.)

Gdb has a feature called a "watchpoint", which does what you want. I don't recall any specifics, but the gdb documentation should tell you about it. (I don't think that PB has any direct support for it. You'll have to type the appropriate commands into the gdb console window. Also, you'll have to find out where in the object the "isa" field is.)

A word of advice: put in more explanation next time. "The ISA is changing" doesn't really mean anything unless the reader knows what you mean by "ISA". For my reply, I'm merely guessing that you mean the "isa" member of the objc_object structure. (Since case is significant, "ISA" isn't necessarily the same as "isa", and all-caps names are often acronyms, such as "CPU" for "Central Processing Unit". My first thought was that you were talking about some register whose name was abbreviated "ISA".)

Glen Fisher
_______________________________________________
projectbuilder-users mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/projectbuilder-users
Do not post admin requests to the list. They will be ignored.

References: 
 >String problem (From: tony cate <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.