Module Name:    src
Committed By:   jmcneill
Date:           Wed Dec  4 14:09:47 UTC 2019

Modified Files:
        src/usr.bin/mkubootimage: mkubootimage.c

Log Message:
Fix signed/unsigned comparison


To generate a diff of this commit:
cvs rdiff -u -r1.25 -r1.26 src/usr.bin/mkubootimage/mkubootimage.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/usr.bin/mkubootimage/mkubootimage.c
diff -u src/usr.bin/mkubootimage/mkubootimage.c:1.25 src/usr.bin/mkubootimage/mkubootimage.c:1.26
--- src/usr.bin/mkubootimage/mkubootimage.c:1.25	Wed Dec  4 11:21:34 2019
+++ src/usr.bin/mkubootimage/mkubootimage.c	Wed Dec  4 14:09:47 2019
@@ -1,4 +1,4 @@
-/* $NetBSD: mkubootimage.c,v 1.25 2019/12/04 11:21:34 jmcneill Exp $ */
+/* $NetBSD: mkubootimage.c,v 1.26 2019/12/04 14:09:47 jmcneill Exp $ */
 
 /*-
  * Copyright (c) 2010 Jared D. McNeill <jmcne...@invisible.ca>
@@ -30,7 +30,7 @@
 #endif
 
 #include <sys/cdefs.h>
-__RCSID("$NetBSD: mkubootimage.c,v 1.25 2019/12/04 11:21:34 jmcneill Exp $");
+__RCSID("$NetBSD: mkubootimage.c,v 1.26 2019/12/04 14:09:47 jmcneill Exp $");
 
 #include <sys/mman.h>
 #include <sys/stat.h>
@@ -433,7 +433,7 @@ write_image(void *hdr, size_t hdrlen, in
 	}
 
 	if (update_image) {
-		if (lseek(kernel_fd, hdrlen, SEEK_SET) != hdrlen) {
+		if (lseek(kernel_fd, hdrlen, SEEK_SET) != (off_t)hdrlen) {
 			perror("seek failed");
 			return errno;
 		}

Reply via email to