bug fixes for YapTab support

git-svn-id: https://yap.svn.sf.net/svnroot/yap/trunk@1259 b08c6af1-5177-4d33-ba66-4b1c6b8b522a
This commit is contained in:
ricroc
2005-03-04 20:30:14 +00:00
parent b729ef2709
commit 4c972ca825
26 changed files with 372 additions and 525 deletions

View File

@@ -41,14 +41,6 @@ ma_h_inner_struct *ma_h_top;
/* ------------------------------------- **
** Local functions declaration **
** ------------------------------------- */
static void receive_signals(int s);
/* ---------------------- **
** Local macros **
** ---------------------- */
@@ -234,7 +226,7 @@ void init_workers(void) {
if (number_workers > 1) {
int son;
son = fork();
if (son == -1) abort_optyap("fork error in function init_workers");
if (son == -1) abort_yapor("fork error in function init_workers");
if (son > 0) {
/* I am the father, I must stay here and wait for my children to all die */
struct sigaction sigact;
@@ -252,7 +244,7 @@ void init_workers(void) {
for (proc = 1; proc < number_workers; proc++) {
int son;
son = fork();
if (son == -1) abort_optyap("fork error in function init_workers");
if (son == -1) abort_yapor("fork error in function init_workers");
if (son == 0) {
/* new worker */
worker_id = proc;
@@ -263,32 +255,4 @@ void init_workers(void) {
}
}
#endif /* YAPOR */
void init_signals(void) {
return;
signal(SIGQUIT, receive_signals);
signal(SIGTERM, receive_signals);
signal(SIGSEGV, receive_signals);
signal(SIGABRT, receive_signals);
signal(SIGFPE, receive_signals);
signal(SIGHUP, receive_signals);
signal(SIGINT, receive_signals);
signal(SIGTSTP, receive_signals);
return;
}
/* ------------------------- **
** Local functions **
** ------------------------- */
static
void receive_signals(int s) {
abort_optyap("receiving signal number %d", s);
return;
}
#endif /* YAPOR || TABLING */