From 4e5f4c52d38cbab9e38dc0fd029cc08cd7a3696f Mon Sep 17 00:00:00 2001 From: "John \"Elwin\" Edwards" Date: Thu, 28 May 2015 10:21:43 -0400 Subject: [PATCH] arogue7, xrogue: rename daemon() to start_daemon(). This prevents conflict with the BSD/OSX daemon() system function. --- arogue7/daemon.c | 4 ++-- arogue7/daemons.c | 2 +- arogue7/main.c | 6 +++--- arogue7/misc.c | 2 +- arogue7/pack.c | 2 +- arogue7/rings.c | 4 ++-- arogue7/wear.c | 4 ++-- xrogue/daemon.c | 4 ++-- xrogue/daemons.c | 2 +- xrogue/main.c | 6 +++--- xrogue/misc.c | 2 +- xrogue/pack.c | 6 +++--- xrogue/rings.c | 4 ++-- xrogue/wear.c | 4 ++-- 14 files changed, 26 insertions(+), 26 deletions(-) diff --git a/arogue7/daemon.c b/arogue7/daemon.c index c70f848..287242a 100644 --- a/arogue7/daemon.c +++ b/arogue7/daemon.c @@ -92,10 +92,10 @@ reg int (*func)(); /* - * daemon: + * start_daemon: * Start a daemon, takes a function. */ -daemon(func, arg, type) +start_daemon(func, arg, type) reg int arg, type, (*func)(); { reg struct delayed_action *dev; diff --git a/arogue7/daemons.c b/arogue7/daemons.c index a38b6e3..214c3c6 100644 --- a/arogue7/daemons.c +++ b/arogue7/daemons.c @@ -110,7 +110,7 @@ register struct thing *tp; swander() { - daemon(rollwand, 0, BEFORE); + start_daemon(rollwand, 0, BEFORE); } /* diff --git a/arogue7/main.c b/arogue7/main.c index bde3518..744de5e 100644 --- a/arogue7/main.c +++ b/arogue7/main.c @@ -383,7 +383,7 @@ char **envp; /* * Start up daemons and fuses */ - daemon(doctor, &player, AFTER); + start_daemon(doctor, &player, AFTER); fuse(swander, 0, WANDERTIME, AFTER); if (player.t_ctype == C_MAGICIAN || player.t_ctype == C_RANGER) fuse(spell_recovery, 0, SPELLTIME, AFTER); @@ -391,11 +391,11 @@ char **envp; fuse(chant_recovery, 0, SPELLTIME, AFTER); if (player.t_ctype == C_CLERIC || player.t_ctype == C_PALADIN) fuse(prayer_recovery, 0, SPELLTIME, AFTER); - daemon(stomach, 0, AFTER); + start_daemon(stomach, 0, AFTER); if (player.t_ctype == C_THIEF || player.t_ctype == C_ASSASIN || player.t_ctype == C_MONK) - daemon(trap_look, 0, AFTER); + start_daemon(trap_look, 0, AFTER); /* Does this character have any special knowledge? */ switch (player.t_ctype) { diff --git a/arogue7/misc.c b/arogue7/misc.c index 758119f..5808f51 100644 --- a/arogue7/misc.c +++ b/arogue7/misc.c @@ -116,7 +116,7 @@ int newclass; * if he becomes a thief then add the trap_look() daemon */ if (newclass == C_THIEF || newclass == C_ASSASIN || newclass == C_MONK) - daemon(trap_look, 0, AFTER); + start_daemon(trap_look, 0, AFTER); char_type = player.t_ctype = newclass; save = pstats.s_hpt; max_stats.s_hpt = pstats.s_hpt = 0; diff --git a/arogue7/pack.c b/arogue7/pack.c index 87eca73..0f92605 100644 --- a/arogue7/pack.c +++ b/arogue7/pack.c @@ -322,7 +322,7 @@ picked_up: else purse = 1; /* fudge to get right msg from eat_gold() */ eat_gold(obj); - daemon(eat_gold, obj, AFTER); + start_daemon(eat_gold, obj, AFTER); } /* For the axe start a fuse to change player to a fighter. */ if (obj->o_which == AXE_AKLAD) diff --git a/arogue7/rings.c b/arogue7/rings.c index 161d494..5ef2c46 100644 --- a/arogue7/rings.c +++ b/arogue7/rings.c @@ -89,9 +89,9 @@ register struct linked_list *item; } } when R_SEARCH: - daemon(ring_search, 0, AFTER); + start_daemon(ring_search, 0, AFTER); when R_TELEPORT: - daemon(ring_teleport, 0, AFTER); + start_daemon(ring_teleport, 0, AFTER); } status(FALSE); if (r_know[obj->o_which] && r_guess[obj->o_which]) diff --git a/arogue7/wear.c b/arogue7/wear.c index 27a315f..f5acca4 100644 --- a/arogue7/wear.c +++ b/arogue7/wear.c @@ -325,7 +325,7 @@ wear() msg("Wearing %s", inv_name(obj,TRUE)); cur_misc[WEAR_GAUNTLET] = obj; if (obj->o_which == MM_FUMBLE) - daemon(fumble, 0, AFTER); + start_daemon(fumble, 0, AFTER); /* * the jewel of attacks does an aggavate monster */ @@ -349,7 +349,7 @@ wear() msg("Wearing %s",inv_name(obj,TRUE)); cur_misc[WEAR_NECKLACE] = obj; msg("The necklace is beginning to strangle you!"); - daemon(strangle, 0, AFTER); + start_daemon(strangle, 0, AFTER); otherwise: msg("What a strange item you have!"); } diff --git a/xrogue/daemon.c b/xrogue/daemon.c index 823c7f7..f64fe63 100644 --- a/xrogue/daemon.c +++ b/xrogue/daemon.c @@ -87,11 +87,11 @@ reg int (*func)(); } /* - * daemon: + * start_daemon: * Start a daemon, takes a function. */ -daemon(dfunc, arg, type) +start_daemon(dfunc, arg, type) reg VOID *arg; reg int type, (*dfunc)(); { diff --git a/xrogue/daemons.c b/xrogue/daemons.c index 0c85335..dc19d2a 100644 --- a/xrogue/daemons.c +++ b/xrogue/daemons.c @@ -113,7 +113,7 @@ register struct thing *tp; swander() { - daemon(rollwand, (VOID *)NULL, BEFORE); + start_daemon(rollwand, (VOID *)NULL, BEFORE); } /* diff --git a/xrogue/main.c b/xrogue/main.c index 010d6ed..e39669f 100644 --- a/xrogue/main.c +++ b/xrogue/main.c @@ -240,7 +240,7 @@ char **envp; /* * Start up daemons and fuses */ - daemon(doctor, &player, AFTER); + start_daemon(doctor, &player, AFTER); fuse(swander, (VOID *)NULL, WANDERTIME, AFTER); /* Give characters their innate abilities */ if (player.t_ctype == C_MAGICIAN || player.t_ctype == C_RANGER) @@ -249,11 +249,11 @@ char **envp; fuse(chant_recovery, (VOID *)NULL, SPELLTIME, AFTER); if (player.t_ctype == C_CLERIC || player.t_ctype == C_PALADIN) fuse(prayer_recovery, (VOID *)NULL, SPELLTIME, AFTER); - daemon(stomach, (VOID *)NULL, AFTER); + start_daemon(stomach, (VOID *)NULL, AFTER); if (player.t_ctype == C_THIEF || player.t_ctype == C_ASSASSIN || player.t_ctype == C_MONK) - daemon(trap_look, (VOID *)NULL, AFTER); + start_daemon(trap_look, (VOID *)NULL, AFTER); /* Does this character have any special knowledge? */ switch (player.t_ctype) { diff --git a/xrogue/misc.c b/xrogue/misc.c index c0fa859..a893d81 100644 --- a/xrogue/misc.c +++ b/xrogue/misc.c @@ -132,7 +132,7 @@ long *newclass; */ if (*newclass == C_THIEF || *newclass == C_ASSASSIN || *newclass == C_MONK) - daemon(trap_look, (VOID *)NULL, AFTER); + start_daemon(trap_look, (VOID *)NULL, AFTER); /* adjust stats */ char_type = player.t_ctype = *newclass; diff --git a/xrogue/pack.c b/xrogue/pack.c index 654f8f1..0f70e5a 100644 --- a/xrogue/pack.c +++ b/xrogue/pack.c @@ -355,7 +355,7 @@ picked_up: else purse = 1; /* fudge to get right msg from eat_gold() */ eat_gold(obj); - daemon(eat_gold, obj, AFTER); + start_daemon(eat_gold, obj, AFTER); } /* start a fuse to change player into a thief */ if (quest_item != MUSTY_DAGGER) { @@ -435,7 +435,7 @@ picked_up: else purse = 1; /* fudge to get right msg */ eat_gold(obj); - daemon(eat_gold, obj, AFTER); + start_daemon(eat_gold, obj, AFTER); } } else { @@ -444,7 +444,7 @@ picked_up: else purse = 1; /* fudge to get right msg */ eat_gold(obj); - daemon(eat_gold, obj, AFTER); + start_daemon(eat_gold, obj, AFTER); } otherwise: diff --git a/xrogue/rings.c b/xrogue/rings.c index ec6ab42..d262c28 100644 --- a/xrogue/rings.c +++ b/xrogue/rings.c @@ -100,9 +100,9 @@ register struct linked_list *item; } } when R_SEARCH: - daemon(ring_search, (VOID *)NULL, AFTER); + start_daemon(ring_search, (VOID *)NULL, AFTER); when R_TELEPORT: - daemon(ring_teleport, (VOID *)NULL, AFTER); + start_daemon(ring_teleport, (VOID *)NULL, AFTER); } status(FALSE); if (r_know[obj->o_which] && r_guess[obj->o_which]) { diff --git a/xrogue/wear.c b/xrogue/wear.c index 3098fd1..0b06b5c 100644 --- a/xrogue/wear.c +++ b/xrogue/wear.c @@ -324,7 +324,7 @@ wear() msg("Wearing %s", inv_name(obj,TRUE)); cur_misc[WEAR_GAUNTLET] = obj; if (obj->o_which == MM_FUMBLE) - daemon(fumble, (VOID *)NULL, AFTER); + start_daemon(fumble, (VOID *)NULL, AFTER); /* * the jewel of attacks does an aggavate monster */ @@ -354,7 +354,7 @@ wear() msg("Wearing %s",inv_name(obj,TRUE)); cur_misc[WEAR_NECKLACE] = obj; msg("The necklace is beginning to strangle you!"); - daemon(strangle, (VOID *)NULL, AFTER); + start_daemon(strangle, (VOID *)NULL, AFTER); otherwise: msg("What a strange item you have!"); }