]> git.lyx.org Git - features.git/commitdiff
Disable forking on Mac OS X. This should fix crashes on Snow Leopard.
authorJean-Marc Lasgouttes <lasgouttes@lyx.org>
Fri, 23 Oct 2009 16:50:40 +0000 (16:50 +0000)
committerJean-Marc Lasgouttes <lasgouttes@lyx.org>
Fri, 23 Oct 2009 16:50:40 +0000 (16:50 +0000)
It would be better to
* detect OS X version at run time (how??)
or
* use proper threads for autosave

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@31696 a592a061-630c-0410-9148-cb99ea01b6c8

src/support/ForkedCalls.cpp

index d1f6c35738f28454bee6b5dbfccbaefe68079a1a..592053b6cf23a6fe04d03ed14f5fa976f5380c7b 100644 (file)
@@ -192,7 +192,13 @@ void ForkedProcess::kill(int tol)
 
 
 pid_t ForkedProcess::fork() {
-#if !defined (HAVE_FORK)
+/* FIXME fork() is not usable on Mac OS X 10.6 (snow leopard) 
+ *   Use something else like threads.
+ *
+ * Since I do not know how to determine at run time what is the OS X
+ * version, I just disable forking altogether for now (JMarc)
+ */
+#if !defined (HAVE_FORK) || defined(__APPLE__)
        return -1;
 #else
        pid_t pid = ::fork();