changeset 107:f2951c4e28d9

Rename daemon() to start_daemon(). daemon() conflicted with the standard library function, which is included by default on OS X.
author John "Elwin" Edwards
date Sat, 07 Sep 2013 08:08:00 -0400
parents c191a735f811
children 2f41b9635c34
files arogue5/daemon.c arogue5/daemons.c arogue5/main.c arogue5/misc.c arogue5/rings.c arogue5/wear.c rogue4/daemon.c rogue4/daemons.c rogue4/main.c srogue/daemon.c srogue/daemons.c srogue/main.c
diffstat 12 files changed, 25 insertions(+), 25 deletions(-) [+]
line wrap: on
line diff
--- a/arogue5/daemon.c	Wed Sep 04 09:01:44 2013 -0700
+++ b/arogue5/daemon.c	Sat Sep 07 08:08:00 2013 -0400
@@ -84,10 +84,10 @@
 
 
 /*
- * 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;
--- a/arogue5/daemons.c	Wed Sep 04 09:01:44 2013 -0700
+++ b/arogue5/daemons.c	Sat Sep 07 08:08:00 2013 -0400
@@ -102,7 +102,7 @@
 
 swander()
 {
-    daemon(rollwand, 0, BEFORE);
+    start_daemon(rollwand, 0, BEFORE);
 }
 
 /*
--- a/arogue5/main.c	Wed Sep 04 09:01:44 2013 -0700
+++ b/arogue5/main.c	Sat Sep 07 08:08:00 2013 -0400
@@ -227,12 +227,12 @@
     /*
      * Start up daemons and fuses
      */
-    daemon(doctor, &player, AFTER);
+    start_daemon(doctor, &player, AFTER);
     fuse(swander, 0, WANDERTIME, AFTER);
-    daemon(stomach, 0, AFTER);
-    daemon(runners, 0, AFTER);
+    start_daemon(stomach, 0, AFTER);
+    start_daemon(runners, 0, AFTER);
     if (player.t_ctype == C_THIEF)
-	daemon(trap_look, 0, AFTER);
+	start_daemon(trap_look, 0, AFTER);
 
     /* Choose a quest item */
     quest_item = rnd(MAXRELIC);
--- a/arogue5/misc.c	Wed Sep 04 09:01:44 2013 -0700
+++ b/arogue5/misc.c	Sat Sep 07 08:08:00 2013 -0400
@@ -702,7 +702,7 @@
 		 * if he becomes a thief then add the trap_look() daemon
 		 */
 		if (obj->o_ac == C_THIEF)
-		    daemon(trap_look, 0, AFTER);
+		    start_daemon(trap_look, 0, AFTER);
 		char_type = player.t_ctype = obj->o_ac;
 		save = pstats.s_hpt;
 		max_stats.s_hpt = pstats.s_hpt = 0;
--- a/arogue5/rings.c	Wed Sep 04 09:01:44 2013 -0700
+++ b/arogue5/rings.c	Sat Sep 07 08:08:00 2013 -0400
@@ -84,9 +84,9 @@
 		}
 	    }
 	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])
--- a/arogue5/wear.c	Wed Sep 04 09:01:44 2013 -0700
+++ b/arogue5/wear.c	Sat Sep 07 08:08:00 2013 -0400
@@ -179,7 +179,7 @@
 		    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
@@ -215,7 +215,7 @@
 		    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!");
--- a/rogue4/daemon.c	Wed Sep 04 09:01:44 2013 -0700
+++ b/rogue4/daemon.c	Sat Sep 07 08:08:00 2013 -0400
@@ -61,10 +61,10 @@
 }
 
 /*
- * daemon:
+ * start_daemon:
  *	Start a daemon, takes a function.
  */
-daemon(func, arg, type)
+start_daemon(func, arg, type)
 int (*func)(), arg, type;
 {
     register struct delayed_action *dev;
--- a/rogue4/daemons.c	Wed Sep 04 09:01:44 2013 -0700
+++ b/rogue4/daemons.c	Sat Sep 07 08:08:00 2013 -0400
@@ -52,7 +52,7 @@
  */
 swander()
 {
-    daemon(rollwand, 0, BEFORE);
+    start_daemon(rollwand, 0, BEFORE);
 }
 
 /*
--- a/rogue4/main.c	Wed Sep 04 09:01:44 2013 -0700
+++ b/rogue4/main.c	Sat Sep 07 08:08:00 2013 -0400
@@ -206,10 +206,10 @@
     /*
      * Start up daemons and fuses
      */
-    daemon(doctor, 0, AFTER);
+    start_daemon(doctor, 0, AFTER);
     fuse(swander, 0, WANDERTIME, AFTER);
-    daemon(stomach, 0, AFTER);
-    daemon(runners, 0, AFTER);
+    start_daemon(stomach, 0, AFTER);
+    start_daemon(runners, 0, AFTER);
     playit();
 }
 
--- a/srogue/daemon.c	Wed Sep 04 09:01:44 2013 -0700
+++ b/srogue/daemon.c	Sat Sep 07 08:08:00 2013 -0400
@@ -85,10 +85,10 @@
 }
 
 /*
- * daemon:
+ * start_daemon:
  *	Start a daemon, takes a function.
  */
-daemon(func, arg, type)
+start_daemon(func, arg, type)
 int arg, type, (*func)();
 {
 	d_insert(func, arg, type, DAEMON);
--- a/srogue/daemons.c	Wed Sep 04 09:01:44 2013 -0700
+++ b/srogue/daemons.c	Sat Sep 07 08:08:00 2013 -0400
@@ -66,7 +66,7 @@
 swander(fromfuse)
 int fromfuse;
 {
-	daemon(rollwand, TRUE, AFTER);
+	start_daemon(rollwand, TRUE, AFTER);
 }
 
 
--- a/srogue/main.c	Wed Sep 04 09:01:44 2013 -0700
+++ b/srogue/main.c	Sat Sep 07 08:08:00 2013 -0400
@@ -243,15 +243,15 @@
 
 	/* Start up daemons and fuses */
 
-	daemon(status, TRUE, BEFORE);
-	daemon(runners, TRUE, AFTER);
+	start_daemon(status, TRUE, BEFORE);
+	start_daemon(runners, TRUE, AFTER);
 	/* 
 	 * These daemons have been moved to AFTER because BEFORE daemons
 	 * get called every command, even invalid ones.  Hopefully this 
 	 * won't break anything.
 	 */
-	daemon(doctor, TRUE, AFTER);
-	daemon(stomach, TRUE, AFTER);
+	start_daemon(doctor, TRUE, AFTER);
+	start_daemon(stomach, TRUE, AFTER);
 	fuse(swander, TRUE, WANDERTIME);
 
 	/* Give the rogue his weaponry */