On May 28, 2009, at 8:39 AM, Jesper Storm Bache wrote:
Does your latest statement mean that the following (from http://developer.apple.com/documentation/CoreFoundation/Conceptual/CFBundles/Tasks/loading.html#//apple_ref/doc/uid/20001127-124675
)
is incorrect/obsolete information:
"You can unloa
Does your latest statement mean that the following (from http://developer.apple.com/documentation/CoreFoundation/Conceptual/CFBundles/Tasks/loading.html#/
/apple_ref/doc/uid/20001127-124675)
is incorrect/obsolete information:
"You can unload the contents of a CFBundle object using
CFBundleUnlo
On May 28, 2009, at 7:52 AM, Andy Lee wrote:
On Wednesday, May 27, 2009, at 11:23PM, "Bill Bumgarner"
wrote:
If you find something that is causing a bundle with Objective-C code
to be unloaded, please file a bug via http://bugreport.apple.com/.
It isn't supported and the number of edge cases
On Wednesday, May 27, 2009, at 11:23PM, "Bill Bumgarner" wrote:
>On May 27, 2009, at 8:20 PM, Andy Lee wrote:
>> I just noticed an earlier message in this thread that points out
>> that stringWithString: does in fact do the same optimization as -
>> copy for constant strings. So the approach i
On May 27, 2009, at 8:20 PM, Andy Lee wrote:
I just noticed an earlier message in this thread that points out
that stringWithString: does in fact do the same optimization as -
copy for constant strings. So the approach in Apple's sample code
does not protect from the bundle unloading problem
I just noticed an earlier message in this thread that points out that
stringWithString: does in fact do the same optimization as -copy for
constant strings. So the approach in Apple's sample code does not
protect from the bundle unloading problem. Aside from the
OTHER_CFLAGS approach Jesp
Assuming that NSString may be using CFStrings, then the issue may be
related to const strings.
See information regarding "OTHER_CFLAGS = -fno-constant-cfstrings"
The basic issue is that when constant cfstrings is enabled, then the
string may be put into the TEXT segment and you end up passing
On Wednesday, May 27, 2009, at 11:48AM, "Michael Ash"
wrote:
>This may seem nitpicky but I see a lot of newbies writing code just
>like this. Their code is filled with stringWithString: calls for
>absolutely no purpose, so I want to discourage that sort of thing.
Just for grins, I searched for c
On 27-May-09, at 8:41 AM, cocoa-dev-requ...@lists.apple.com wrote:
Well I am trying to find where is my mistake, since sometimes my
application crashes and I am quite (99.9%) sure that I am releasing a
object that shouldn't be.
Any ideas how to find such a bug?
As long as the crashes happen
Thanks to all!
NSZombiesEnabled YES
Is really helpfull, now I now where to start!;)
I wish I would have known this before.
Cheers
On Thu, May 28, 2009 at 12:38 AM, Bill Bumgarner wrote:
> On May 27, 2009, at 8:34 AM, Ignacio Enriquez wrote:
>>
>> And regarding why use retainCount?
>> Well I am
On Wed, May 27, 2009 at 11:05 AM, Erik Buck wrote:
> As an alternative, use
> NSString *string1 = [[NSString stringWithString:@"myFirstString"] retain];
> or NSString *string2 = [[NSString alloc] initWithString:@"mySecondString"];
> or NSString *string3 = [@"myThirdString" copy];
However you shou
On May 27, 2009, at 8:34 AM, Ignacio Enriquez wrote:
And regarding why use retainCount?
Well I am trying to find where is my mistake, since sometimes my
application crashes and I am quite (99.9%) sure that I am releasing a
object that shouldn't be.
Using -retainCount won't help you; a temptin
First:
I just realized that one of my statements was incorrect;
NSString *string2 = [[NSString alloc] initWithFormat:@"mySecondString"];
does not make string2 retainCount to be 2147483647, it only becomes
2147483647 when inserting @"" instead of @"mySecondString"
And regarding why use retainC
On Wed, May 27, 2009 at 9:59 AM, Ignacio Enriquez wrote:
>
> 1.- What is the difference between string1 and string2? where
> NSString *string1 = [NSString stringWithFormat:@"myFirstString"];
> NSString *string2 = [[NSString alloc] initWithFormat:@"mySecondString"];
You own string2 and must rele
Don't ever write either of the following lines:
> NSString *string1 = [NSString stringWithFormat:@"myFirstString"];
> NSString *string2 = [[NSString alloc]
initWithFormat:@"mySecondString"];
the WithFormat methods parse the argument string. If your argument
string contains any '%' character
Hi Ignacio,
I just ran a simple test, pasted below:
NSString * one = [NSString stringWithString:@"Hello"];
NSString * two = [[NSString alloc] initWithString:@"Hello"];
NSLog(@"%X, %X, %X", one, two, @"Hello");
What you see logged is that the three strings point to the sa
On 27/05/2009, at 11:59 PM, Ignacio Enriquez wrote:
I have a basic question regarding Class methods and instance methods
and memory allocation. (this is in iPhone OS 3.0 beta 5)
1.- What is the difference between string1 and string2? where
NSString *string1 = [NSString stringWithFormat:@"myFir
On May 27, 2009, at 6:59 AM, Ignacio Enriquez wrote:
Hi.
I have a basic question regarding Class methods and instance methods
and memory allocation. (this is in iPhone OS 3.0 beta 5)
1.- What is the difference between string1 and string2? where
NSString *string1 = [NSString stringWithFormat:@"my
Hi.
I have a basic question regarding Class methods and instance methods
and memory allocation. (this is in iPhone OS 3.0 beta 5)
1.- What is the difference between string1 and string2? where
NSString *string1 = [NSString stringWithFormat:@"myFirstString"];
NSString *string2 = [[NSString alloc] in
19 matches
Mail list logo