From: Ari Johnson Date: Sat, 3 Mar 2007 00:26:14 +0000 (+0000) Subject: Various %c weirdness X-Git-Url: https://git.theari.com/?a=commitdiff_plain;h=8a3f1fc71a6006ef86a0c560503e19b2b7290798;p=cobramush.git Various %c weirdness (cherry picked from commit 393db0fc7dd7c7a40a834aeac49846f33c4f9757) --- diff --git a/src/bsd.c b/src/bsd.c index e77af91..36be4a3 100644 --- a/src/bsd.c +++ b/src/bsd.c @@ -3544,6 +3544,7 @@ announce_connect(dbref player, int isnew, int num) global_eval_context.wnxt[j] = NULL; for (j = 0; j < NUMQ; j++) global_eval_context.rnxt[j] = NULL; + strcpy(global_eval_context.ccom, ""); /* do the person's personal connect action */ (void) queue_attribute(player, "ACONNECT", player); diff --git a/src/console.c b/src/console.c index 00933c9..5e06c3d 100644 --- a/src/console.c +++ b/src/console.c @@ -2826,6 +2826,7 @@ announce_connect(dbref player, int isnew, int num) global_eval_context.wnxt[j] = NULL; for (j = 0; j < NUMQ; j++) global_eval_context.rnxt[j] = NULL; + strcpy(global_eval_context.ccom, ""); /* do the person's personal connect action */ (void) queue_attribute(player, "ACONNECT", player); @@ -2896,6 +2897,7 @@ announce_disconnect(dbref player) global_eval_context.wnxt[j] = NULL; for (j = 0; j < NUMQ; j++) global_eval_context.rnxt[j] = NULL; + strcpy(global_eval_context.ccom, ""); /* Setup all connect information as info to pass */ (void) queue_attribute(player, "ADISCONNECT", player); diff --git a/src/cque.c b/src/cque.c index b370bd9..300970e 100644 --- a/src/cque.c +++ b/src/cque.c @@ -650,8 +650,10 @@ do_top(int ncom) for (i = 0; i < ncom; i++) { - if (!qfirst) + if (!qfirst) { + strcpy(global_eval_context.ccom, ""); return i; + } /* We must dequeue before execution, so that things like * queued @kick or @ps get a sane queue image. */ diff --git a/src/timer.c b/src/timer.c index e66fa4f..9ddc82e 100644 --- a/src/timer.c +++ b/src/timer.c @@ -234,6 +234,7 @@ dispatch(void) global_eval_context.cplr = NOTHING; strcpy(global_eval_context.ccom, "purge"); purge(); + strcpy(global_eval_context.ccom, ""); } if (options.dbck_counter <= mudtime) { @@ -242,6 +243,7 @@ dispatch(void) global_eval_context.cplr = NOTHING; strcpy(global_eval_context.ccom, "dbck"); dbck(); + strcpy(global_eval_context.ccom, ""); } if (idle_counter <= mudtime) { @@ -257,6 +259,7 @@ dispatch(void) global_eval_context.cplr = NOTHING; strcpy(global_eval_context.ccom, "dump"); fork_and_dump(1); + strcpy(global_eval_context.ccom, ""); flag_broadcast(0, "ON-VACATION", "%s", T ("Your ON-VACATION flag is set! If you're back, clear it.")); @@ -274,6 +277,7 @@ dispatch(void) global_eval_context.cplr = NOTHING; strcpy(global_eval_context.ccom, "warnings"); run_topology(); + strcpy(global_eval_context.ccom, ""); } #ifdef MUSHCRON if((mudtime % 60) == 0)