On 03/04/2008, at 10:17 AM, Jonatan Liljedahl wrote:
Hi all, this is actually not directly related to Inkscape but to the Mac OS X .app launcher, which I have borrowed for use in my own project (http://kymatica.com/algoscore). But this might be a bug that affects Inkscape users too:
I see in ScriptExec/main.c that it is supposed to show an error dialog if X11 was not found. This doesn't seem to be working, it just says "unexpected termination" or similar and crashes. I wonder about these lines:
// custom carbon events #define kEventClassRedFatalAlert 911 #define kEventKindX11Failed 911 #define kEventKindFCCacheFailed 912
I know nothing about Carbon or other OS X stuff, but should the first two really be the same numbers?
Hi Jonaton,
Those lines are actually okay, since the first defines a custom EventClass and the second two (which must *each* be unique) define EventTypes.
I have separated them in the source and added an extra comment, so that they no longer look suspicious.
I can't explain why your code would crash with "unexpected termination" other than to expalain that this ScriptExec program calls one of two shell scripts (Resources/script or Resources/openDoc). The first is called when Inkscape is launched. It attempts to start X11.app (on machines running Tiger or earlier) and then returns an error code if X11 is not running. This error code is noticed by the ScriptExec app, which then shows the error dialog. On Leopard, X11 is installed by default and is started by the launchd program, so we don't check for it.
Cheers, Michael