Permalink
Browse files

Fix type errors in format strings.

  • Loading branch information...
1 parent 44ca999 commit 2862515e2347f3a74f22254ca64f63316cde1e49 @jonm committed Oct 12, 2015
Showing with 6 additions and 6 deletions.
  1. +3 −3 src/act.info.c
  2. +3 −3 src/act.wizard.c
View
@@ -2779,7 +2779,7 @@ void do_world(struct char_data *ch, char *argument, int cmd)
#if HASH
sprintf(buf, "Total number of rooms in world: %d\n\r", room_db.klistlen);
#else
- sprintf(buf, "Total number of rooms in world: %d\n\r", room_count);
+ sprintf(buf, "Total number of rooms in world: %ld\n\r", room_count);
#endif
send_to_char(buf, ch);
sprintf(buf, "Total number of zones in world: %d\n\r\n\r",
@@ -2794,10 +2794,10 @@ void do_world(struct char_data *ch, char *argument, int cmd)
sprintf(buf,"Total number of registered players: %d\n\r",top_of_p_table + 1);
send_to_char(buf, ch);
- sprintf(buf, "Total number of monsters in game: %d\n\r", mob_count);
+ sprintf(buf, "Total number of monsters in game: %ld\n\r", mob_count);
send_to_char(buf, ch);
- sprintf(buf, "Total number of objects in game: %d\n\r", obj_count);
+ sprintf(buf, "Total number of objects in game: %ld\n\r", obj_count);
send_to_char(buf, ch);
}
View
@@ -1236,7 +1236,7 @@ void do_stat(struct char_data *ch, char *argument, int cmd)
strcat(buf, buf2);
send_to_char(buf, ch);
- sprintf(buf,"Birth : [%ld]secs, Logon[%ld]secs, Played[%ld]secs\n\r",
+ sprintf(buf,"Birth : [%ld]secs, Logon[%ld]secs, Played[%d]secs\n\r",
k->player.time.birth,
k->player.time.logon,
k->player.time.played);
@@ -1387,7 +1387,7 @@ void do_stat(struct char_data *ch, char *argument, int cmd)
if(aff->location == APPLY_IMMUNE && !(aff->modifier) &&
aff->bitvector) {
sprintf(buf, "Spell : '%s'\n\r",spells[aff->type-1]);
- sprintf(buf," Modifies %s by %d points\n\r",
+ sprintf(buf," Modifies %s by %ld points\n\r",
apply_types[aff->location],aff->bitvector);
send_to_char(buf,ch);
sprintf(buf," Expires in %3d hours, Resistance Bits set ",
@@ -1608,7 +1608,7 @@ void do_stat(struct char_data *ch, char *argument, int cmd)
send_to_char("Can affect char :\n\r", ch);
for (i=0;i<MAX_OBJ_AFFECT;i++) {
sprinttype(j->affected[i].location,apply_types,buf2);
- sprintf(buf," Affects : %s By %d\n\r", buf2,j->affected[i].modifier);
+ sprintf(buf," Affects : %s By %lu\n\r", buf2,j->affected[i].modifier);
send_to_char(buf, ch);
}
return;

0 comments on commit 2862515

Please sign in to comment.