From 6709c6ff3b9455f1241b463647318096b36d29f8 Mon Sep 17 00:00:00 2001 From: Rick L Bird Date: Sat, 14 May 2011 14:01:51 -0400 Subject: [PATCH] PennMUSH 1.8.3p12 Author: talvo@talvo.com Date: Tue Jan 26 00:21:22 2010 +0000 Fix a minor crashbug in @uptime Fixes #222 --- src/game.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/game.c b/src/game.c index e161c3d..15b639f 100644 --- a/src/game.c +++ b/src/game.c @@ -2166,7 +2166,7 @@ unix_uptime(dbref player __attribute__ ((__unused__))) return; } /* print system uptime */ - for (i = 0; (c = getc(fp)) != '\n'; i++) + for (i = 0; (c = getc(fp)) != '\n' && c != EOF ; i++) tbuf1[i] = c; tbuf1[i] = '\0'; pclose(fp); -- 2.30.2