]> granicus.if.org Git - nethack/commitdiff
Fixed coding error. strlen() returns size_t causing a size_t sized value pushed onto...
authorBart House <bart@barthouse.com>
Sat, 2 Sep 2017 18:29:23 +0000 (11:29 -0700)
committerPasi Kallinen <paxed@alt.org>
Mon, 4 Sep 2017 09:41:53 +0000 (12:41 +0300)
util/dlb_main.c

index 0a4b938dd7a58220d5bb86fbcdf19894c47dda32..6cda2b3ab9ece42be6129ec9e5cda2f13eff2829 100644 (file)
@@ -506,7 +506,7 @@ long slen, dir_size, flen;
             (long) DLB_VERS,   /* version of dlb file */
             (long) nfiles + 1, /* # of entries (includes directory) */
                                /* string length + room for nulls */
-            (long) slen + strlen(DLB_DIRECTORY) + nfiles + 1,
+            (long) slen + (long) strlen(DLB_DIRECTORY) + nfiles + 1,
             (long) dir_size,         /* start of first file */
             (long) flen + dir_size); /* total file size */
     Write(out, buf, strlen(buf));