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: (no subject)



On Jan 30, 2007, at 8:20 PM, amber maheshwari wrote:

I am working on new INTEL Dual Core mac mini.
My application is a java application and I am making native function call through java
and the problem is that a crash occurs when I call method showMenuBar() and HideMenuBar()
in my application through JNI.
Crash is occuring when I am calling hide & show menu method frequently one by one.
Also this crash is occuring only with Mac mini intel dual core machine and not with other Mac machines.


The crash report is following :
0 com.apple.CoreGraphics 0x903869a3 CGClipStackGetClipAtIndex + 21


[snip]

26  com.apple.HIToolbox                 0x92fde8fa ShowMenuBar + 122

[snip]

58 libjvm.dylib 0x95c4abc4 JVM_StartThread + 1726
59 libjvm.dylib 0x95bfcea3 JNI_CreateJavaVM_Impl + 34773
60 libSystem.B.dylib 0x90024b07 _pthread_body + 84

You should really read the headers (HIToolbox/Menus.h in this case). ShowMenuBar is not thread-safe. I don't know why the crash isn't occurring on other machines, other than you might just be lucky in those cases.


/*
*  ShowMenuBar()
*
*  Mac OS X threading:
*    Not thread safe
*
*  Availability:
*    Mac OS X:         in version 10.0 and later in Carbon.framework
*    CarbonLib:        in CarbonLib 1.0 and later
*    Non-Carbon CFM:   in MenusLib 8.5 and later
*/
extern void
ShowMenuBar(void) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;

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

This email sent to email@hidden
References: 
 >(no subject) (From: "amber maheshwari" <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.