On Fri, Jul 11, 2008 at 7:20 AM, Sean McBride <[EMAIL PROTECTED]> wrote:
> Hi all,
>
> The following works just fine in non-GC apps when called in an IBAction
> method:
>
>        NSSpeechSynthesizer* speechSynthesizer =
>    [[[NSSpeechSynthesizer alloc] init] autorelease];
>        [speechSynthesizer startSpeakingString:
>    @"Hello. I'm Macintosh. It sure is great to get out of that bag."];
>
> In GC apps it crashes (non main thread):
>
> #0  0x907586e8 in objc_msgSend ()
> #1  0x952f6f23 in SpeechDoneProc ()
> #2  0x1f00d979 in MTBEDoneTask::Execute ()
> #3  0x1f018b01 in MTBEWorker::WorkLoop ()
> #4  0x1f018b5d in MTBEWorkerStartMPTask ()
> #5  0x91ec555b in PrivateMPEntryPoint ()
> #6  0x96fa76f5 in _pthread_start ()
> #7  0x96fa75b2 in thread_start ()
>
> I'm guessing this is because the speechSynthesizer is collected before
> it finishes speaking.  Is this 'correct behaviour' or a bug?  Needless
> to say, the docs say nothing about special considerations for garbage
> collection.  My speechSynthesizer has no delegate, and I don't care when
> it starts or stops speaking.  Shouldn't that make it
> NSSpeechSynthesizer's job to keep itself alive until it finishes
> speaking?  Afterall, _I'm_ finished with the speechSynthesizer.

If I were you, I'd file a Bug.


-- 
Clark S. Cox III
[EMAIL PROTECTED]
_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [EMAIL PROTECTED]

Reply via email to