Re: Strange behaviour of iPhone
Re: Strange behaviour of iPhone
- Subject: Re: Strange behaviour of iPhone
- From: "Gerriet M. Denkmann" <email@hidden>
- Date: Sun, 22 Sep 2013 00:43:49 +0700
On 22 Sep 2013, at 00:38, "Mills, Steve" <email@hidden> wrote:
>> On Sep 21, 2013, at 12:24, "Gerriet M. Denkmann" <email@hidden> wrote:
>>
>> 1. tupelsP lives outside the block
>
> Because once the block containing the array exits scope, so does the memory of the array. tuplesP is pointing to memory that is no longer valid.
Ok. I am convinced.
But why no compiler error? Like: "assigning a global pointer to local storage is illegal"?
I have changed my code accordingly and all is fine.
Kind regards,
Gerriet.
_______________________________________________
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