summaryrefslogtreecommitdiff
path: root/src/map/chrif.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/map/chrif.c')
-rw-r--r--src/map/chrif.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/map/chrif.c b/src/map/chrif.c
index 1adee71a9..4b5dde218 100644
--- a/src/map/chrif.c
+++ b/src/map/chrif.c
@@ -1246,7 +1246,8 @@ int chrif_load_scdata(int fd)
WFIFOW(char_fd,6) = drop_rate;
if ((fp = fopen(motd_txt, "r")) != NULL) {
- if (fgets(buf, 250, fp) != NULL) {
+ if (fgets(buf, sizeof(buf), fp) != NULL)
+ {
for(i = 0; buf[i]; i++) {
if (buf[i] == '\r' || buf[i] == '\n') {
buf[i] = 0;