From 06f969f8132e7aaa1c6bb559d4611416d4120b59 Mon Sep 17 00:00:00 2001 From: Adam Dickmeiss Date: Thu, 18 May 1995 12:03:08 +0000 Subject: [PATCH] Bug fixes and minor improvements. --- kernel/default.fml | 6 +++--- kernel/main.c | 6 +++++- kernel/monitor.c | 13 +++++++++---- kernel/urp.c | 7 +++++-- 4 files changed, 22 insertions(+), 10 deletions(-) diff --git a/kernel/default.fml b/kernel/default.fml index d512392..29c21b5 100644 --- a/kernel/default.fml +++ b/kernel/default.fml @@ -1,5 +1,5 @@ # Fml scripts to display MARC records -# $Id: default.fml,v 1.4 1995/03/02 09:32:10 adam Exp $ +# $Id: default.fml,v 1.5 1995/05/18 12:03:08 adam Exp $ \func f0 rec { \foreach line {\rec} { \line \index 1 \ @@ -56,7 +56,7 @@ \foreach line {\rec} {\code} } -\func f1 record { +\func f2 record { \marc {\record} { \case 245 .. [a] { \info } 60 \case 260 .. c { - \info} 9 @@ -64,7 +64,7 @@ \n } -\func f2 record { +\func f1 record { \foreach line {\record} { \case 245 .. [ab] {\info\ } 400 \casx 260 [abc] {\n\ \ \info} {\ \info} {} diff --git a/kernel/main.c b/kernel/main.c index 4f4b0b7..0f511c7 100644 --- a/kernel/main.c +++ b/kernel/main.c @@ -45,7 +45,10 @@ * Europagate, 1995 * * $Log: main.c,v $ - * Revision 1.25 1995/05/16 09:40:42 adam + * Revision 1.26 1995/05/18 12:03:08 adam + * Bug fixes and minor improvements. + * + * Revision 1.25 1995/05/16 09:40:42 adam * LICENSE. Setting of CCL token names (and/or/not/set) in read_kernel_res. * * Revision 1.24 1995/05/04 10:40:07 adam @@ -397,6 +400,7 @@ int main (int argc, char **argv) gw_log (GW_LOG_FATAL, KERNEL_LOG, "missing user id"); exit (1); } + gw_log_session (info.userid); break; default: gw_log (GW_LOG_FATAL, KERNEL_LOG, "unknown option %s", *argv); diff --git a/kernel/monitor.c b/kernel/monitor.c index e385ec2..aeb5cb7 100644 --- a/kernel/monitor.c +++ b/kernel/monitor.c @@ -45,7 +45,10 @@ * Europagate, 1995 * * $Log: monitor.c,v $ - * Revision 1.9 1995/05/17 10:51:32 adam + * Revision 1.10 1995/05/18 12:03:09 adam + * Bug fixes and minor improvements. + * + * Revision 1.9 1995/05/17 10:51:32 adam * Added a few more error checks to the show command. * * Revision 1.8 1995/05/16 09:40:42 adam @@ -192,7 +195,7 @@ static void catch_child (int num) for (ki = ke_info_list; ki; ki = ki->next) if (ki->pid == pid) ki->pid = -1; -/* --no_process;*/ + --no_process; } signal (SIGCHLD, catch_child); } @@ -415,7 +418,10 @@ static void monitor_events (int argc, char **argv) r = deliver (argc, argv, ki->id, ki->queue, &ki->gip, &ki->pid, no_process >= max_process); if (r == 2) /* new child was spawned? */ + { ++no_process; + gw_log (GW_LOG_DEBUG, module, "Start of %d", ki->id); + } if (r == 1 || r == 2) /* transfer at all? */ str_queue_rm (&ki->queue); if (r == 0) /* too many pending? */ @@ -463,7 +469,6 @@ static void monitor_events (int argc, char **argv) gipc_close (ki->gip); gipc_destroy (ki->gip); ki->gip = NULL; - --no_process; } else if ((fd = gip_infileno (ki->gip)) != -1) { /* read select on child FIFO */ @@ -508,7 +513,6 @@ static void monitor_events (int argc, char **argv) gipc_close (ki->gip); gipc_destroy (ki->gip); ki->gip = NULL; - --no_process; } } } @@ -590,6 +594,7 @@ int main (int argc, char **argv) signal (SIGTERM, catch_term); signal (SIGINT, catch_int); #if 1 + gw_log_level (GW_LOG_ALL & ~RES_DEBUG); gw_log_file (GW_LOG_ALL, "monitor.log"); #endif monitor_events (argc, argv); diff --git a/kernel/urp.c b/kernel/urp.c index 4a23bb8..820a39b 100644 --- a/kernel/urp.c +++ b/kernel/urp.c @@ -45,7 +45,10 @@ * Europagate, 1995 * * $Log: urp.c,v $ - * Revision 1.36 1995/05/17 10:51:33 adam + * Revision 1.37 1995/05/18 12:03:09 adam + * Bug fixes and minor improvements. + * + * Revision 1.36 1995/05/17 10:51:33 adam * Added a few more error checks to the show command. * * Revision 1.35 1995/05/16 09:40:43 adam @@ -1127,7 +1130,7 @@ void urp_end (void) mta = gw_res_get (info.kernel_res, "gw.reply.mta", "/usr/lib/sendmail"); sprintf (cmd, "%s %s < %s", mta, info.from_str, info.reply_fname); -#if 1 +#if 0 mta_code = system (cmd); if (mta_code) gw_log (GW_LOG_FATAL, KERNEL_LOG, -- 1.7.10.4