mirror of
https://git.lyx.org/repos/lyx.git
synced 2025-01-10 18:58:10 +00:00
Enable compilation on various platforms.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@9849 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
a2f413c035
commit
ce286c29ba
@ -1,3 +1,10 @@
|
||||
2005-04-21 Angus Leeming <leeming@lyx.org>
|
||||
|
||||
* forkedcontr.C: add #include <csignal>.
|
||||
|
||||
* filetools.C (RunCommand): remove the signal blocking stuff
|
||||
now that we no longer use a signal handler on unix.
|
||||
|
||||
2005-04-19 Angus Leeming <leeming@lyx.org>
|
||||
|
||||
* filetools.C: remove unnecessary #include of forkedcontr.h.
|
||||
|
@ -43,9 +43,9 @@
|
||||
#include <fcntl.h>
|
||||
|
||||
#include <cctype>
|
||||
#include <cerrno>
|
||||
#include <cstdlib>
|
||||
#include <cstdio>
|
||||
#include <cerrno>
|
||||
|
||||
#include <utility>
|
||||
#include <fstream>
|
||||
@ -1061,14 +1061,6 @@ cmd_ret const RunCommand(string const & cmd)
|
||||
// pstream (process stream), with the
|
||||
// variants ipstream, opstream
|
||||
|
||||
sigset_t newMask, oldMask;
|
||||
sigemptyset(&oldMask);
|
||||
sigemptyset(&newMask);
|
||||
sigaddset(&newMask, SIGCHLD);
|
||||
|
||||
// Block the SIGCHLD signal.
|
||||
sigprocmask(SIG_BLOCK, &newMask, &oldMask);
|
||||
|
||||
FILE * inf = ::popen(cmd.c_str(), os::popen_read_mode());
|
||||
|
||||
// (Claus Hentschel) Check if popen was succesful ;-)
|
||||
@ -1087,9 +1079,6 @@ cmd_ret const RunCommand(string const & cmd)
|
||||
if (pret == -1)
|
||||
perror("RunCommand:: could not terminate child process");
|
||||
|
||||
// Unblock the SIGCHLD signal and restore the old mask.
|
||||
sigprocmask(SIG_SETMASK, &oldMask, 0);
|
||||
|
||||
return make_pair(pret, ret);
|
||||
}
|
||||
|
||||
|
@ -25,6 +25,7 @@
|
||||
|
||||
#else
|
||||
# include <cerrno>
|
||||
# include <csignal>
|
||||
# include <cstdlib>
|
||||
# include <unistd.h>
|
||||
# include <sys/wait.h>
|
||||
|
Loading…
Reference in New Issue
Block a user