lyx_mirror/src/support
Richard Heck 1741c87a4e Fix bug 4463. The crash was due to a call to X from inside a child process.
The main change is to support/ForkedCalls.{h,cpp}. We introduce a static variable IAmAChild and a corresponding accessor. This is set to true in a new fork() method, in the branch taken by the child. (Note: fork() is safe cross-platform, as it just returns -1 if we don't have fork().) This ForkedProcess::iAmAChild() method is then used to protect GuiView::message().

As Abdel has pointed out, there may be other such calls to be protected, e.g., the emission of the Buffer::changed() signal. Those are not addressed here.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@22587 a592a061-630c-0410-9148-cb99ea01b6c8
2008-01-15 18:26:53 +00:00
..
minizip zipunzip.cpp: Replace makedir etc with versions in support::FileName, fix a bug in extracting subdirectories 2008-01-05 04:39:01 +00:00
tests getting rid of superfluous std:: statements. 2007-12-12 19:28:07 +00:00
atexit.c
convert.cpp 'using namespace std' instead of 'using std::xxx' 2007-12-12 10:16:00 +00:00
convert.h cosmetics 2007-11-10 13:44:50 +00:00
copied_ptr.h
debug.cpp * added debugging flag "macros" for math macros 2007-12-21 20:43:21 +00:00
debug.h * added debugging flag "macros" for math macros 2007-12-21 20:43:21 +00:00
docstream.cpp Following rev 21967: final touch to odocfstream: 2007-12-29 18:04:43 +00:00
docstream.h Following rev 21967: final touch to odocfstream: 2007-12-29 18:04:43 +00:00
docstring.cpp Another compile fix 2007-12-12 21:09:51 +00:00
docstring.h cosmetics. mainly replace #include "dostring.h" by #include "strfwd.h" 2007-11-01 22:17:22 +00:00
environment.cpp getting rid of superfluous std:: statements. 2007-12-12 19:28:07 +00:00
environment.h
ExceptionMessage.h introduce a header to forward declare std::string. 2007-10-31 22:40:34 +00:00
FileFilterList.cpp getting rid of superfluous std:: statements. 2007-12-12 19:28:07 +00:00
FileFilterList.h cosmetics 2007-11-10 13:44:50 +00:00
FileMonitor.cpp header cleanup. 2007-12-16 22:09:28 +00:00
FileMonitor.h Add FIXMEs 2007-11-30 09:49:35 +00:00
FileName.cpp * FileName::onlyPath(): use correct method. I need glasses! 2007-12-18 10:34:53 +00:00
FileName.h Embedding: add embedding support for InsetInclude. (params["embed"] is added) 2008-01-08 16:35:43 +00:00
FileNameList.h Embedding: merge lyx::EmbeddedFiles to lyx::support::EmbeddedFileList 2008-01-08 18:55:34 +00:00
filetools.cpp Now that exceptions are allowed, handle gracefully the case where a Buffer temp directory could not be created. As a bonus, the user will get an informative message. 2007-12-17 18:37:13 +00:00
filetools.h Now that exceptions are allowed, handle gracefully the case where a Buffer temp directory could not be created. As a bonus, the user will get an informative message. 2007-12-17 18:37:13 +00:00
FileZipListDir.h Introducing FileNameList, cleanup some headers and put back dirList() into FileName. 2007-12-05 10:32:49 +00:00
ForkedCalls.cpp Fix bug 4463. The crash was due to a call to X from inside a child process. 2008-01-15 18:26:53 +00:00
ForkedCalls.h Fix bug 4463. The crash was due to a call to X from inside a child process. 2008-01-15 18:26:53 +00:00
gettext.cpp 'using namespace std' instead of 'using std::xxx' 2007-12-12 10:16:00 +00:00
gettext.h Move debug.{cpp,h}, Messages.{cpp,h} and gettext.{cpp,h} to support/. 2007-11-29 07:04:28 +00:00
gzstream.cpp getting rid of superfluous std:: statements. 2007-12-12 19:28:07 +00:00
gzstream.h * src/support/gzstream,cpp: 2007-08-01 15:16:44 +00:00
kill.cpp compile fix for mingw 2007-12-01 00:10:04 +00:00
limited_stack.h
lstrings.cpp header cleanup. 2007-12-16 22:09:28 +00:00
lstrings.h cosmetics 2007-12-12 22:43:37 +00:00
lyxalgo.h disable some tests for standard C++ features; add a line counting stream for lates output 2007-08-12 08:57:17 +00:00
lyxlib.h Sanitize the way we use abort() and exit(). With this commit, we should never crash in release mode, even when assertions are enabled. In debug mode, we crash with abort in order to get a useful backtrace. 2007-12-16 11:34:29 +00:00
lyxsum.cpp header cleanup. 2007-12-16 22:09:28 +00:00
lyxtime.cpp 'using namespace std' instead of 'using std::xxx' 2007-12-12 10:16:00 +00:00
lyxtime.h - Get rid of unneeded time_type typedef. 2007-11-29 08:55:43 +00:00
Makefile.am Sanitize the way we use abort() and exit(). With this commit, we should never crash in release mode, even when assertions are enabled. In debug mode, we crash with abort in order to get a useful backtrace. 2007-12-16 11:34:29 +00:00
Messages.cpp revert r22574 to be able to compile 2008-01-14 23:45:04 +00:00
Messages.h Move debug.{cpp,h}, Messages.{cpp,h} and gettext.{cpp,h} to support/. 2007-11-29 07:04:28 +00:00
os_cygwin.cpp * get rid of support::absolutePath() 2007-12-17 16:04:46 +00:00
os_unix.cpp * get rid of support::absolutePath() 2007-12-17 16:04:46 +00:00
os_win32.cpp * get rid of support::absolutePath() 2007-12-17 16:04:46 +00:00
os_win32.h
os.cpp getting rid of superfluous std:: statements. 2007-12-12 19:28:07 +00:00
os.h transfer os::is_absolute_path() to FileName::isAbsolute(). 2007-12-17 15:15:37 +00:00
Package.cpp transfer os::is_absolute_path() to FileName::isAbsolute(). 2007-12-17 15:15:37 +00:00
Package.h cosmetics 2007-11-02 21:04:52 +00:00
Path.cpp header cleanup. 2007-12-16 22:09:28 +00:00
Path.h fix merge build 2007-12-02 09:24:26 +00:00
pch.h shuffle stuff around 2007-11-08 00:09:58 +00:00
qstring_helpers.h Inline qstring_helpers methods. 2007-11-26 10:26:03 +00:00
RandomAccessList.h boost/utility -> boost/noncopyable 2007-09-30 15:47:00 +00:00
SignalSlot.cpp Encoding. 2007-12-29 21:15:20 +00:00
SignalSlot.h Encoding. 2007-12-29 21:15:20 +00:00
SignalSlotPrivate.cpp pch fix 2007-12-02 09:58:23 +00:00
SignalSlotPrivate.h More encoding. 2007-12-29 21:18:50 +00:00
socktools.cpp compile fix. 2007-12-17 10:51:39 +00:00
socktools.h
strerror.c
strfwd.h I'll find a solution for the 'dirList problem', Abdel. 2007-11-30 20:57:53 +00:00
Systemcall.cpp getting rid of superfluous std:: statements. 2007-12-12 19:28:07 +00:00
Systemcall.h Revert qprocess code. Revisions reverted: 22026, 22030, 22044, 22048, 2007-12-12 18:25:53 +00:00
textutils.h introduce a header to forward declare std::string. 2007-10-31 22:40:34 +00:00
Timeout.cpp getting rid of superfluous std:: statements. 2007-12-12 19:28:07 +00:00
Timeout.h simplify class structure 2007-11-12 20:18:19 +00:00
Translator.h 172725 lines down 2007-10-25 19:41:06 +00:00
types.h Introducing TextClassPtr.h to minimize header dependencies. 2007-11-07 23:25:08 +00:00
unicode.cpp * src/support/unicode.cpp (convert): 2007-12-27 07:30:06 +00:00
unicode.h cosmetics 2007-11-29 07:24:55 +00:00
userinfo.cpp 'using namespace std' instead of 'using std::xxx' 2007-12-12 10:16:00 +00:00
userinfo.h introduce a header to forward declare std::string. 2007-10-31 22:40:34 +00:00