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: Singleton class -init being called twice?



On Sun, 31 Oct 2004 08:59:06 +0100, Ole Voss <email@hidden> wrote:
>
> I just noticed that the -init routine from my singleton is being called
> twice:
>
> 1) When being 'alloc'ated.
> 2) When being 'init'ed.
>
> Does this pose a problem or am I doing something wrong?

What you just said make no sense -init only gets called when someone
calls -init, and calling +alloc doesn't call -init. How are you
creating your object?

-- Finlay
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/email@hidden

This email sent to email@hidden

References: 
 >Singleton class -init being called twice? (From: Ole Voss <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.