Skip to content

Commit

Permalink
dumpon: fix build on some architectures
Browse files Browse the repository at this point in the history
Fix a -Wsign-compare issue on some architectures.

Fixes:		96f9bd4
Pointy hat to:	me
MFC after:	1 week
Sponsored by:	Dell EMC Isilon
  • Loading branch information
vangyzen committed Aug 12, 2021
1 parent a3ff18e commit 080c6fd
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions sbin/dumpon/dumpon.c
Original file line number Diff line number Diff line change
Expand Up @@ -334,7 +334,7 @@ genkey(const char *pubkeyfile, struct diocskerneldump_arg *kdap)
err(1, "genkey pipe write");
bytes = write(filedes[1], kdap->kda_encryptedkey,
kdap->kda_encryptedkeysize);
if (bytes != kdap->kda_encryptedkeysize)
if (bytes != (ssize_t)kdap->kda_encryptedkeysize)
err(1, "genkey pipe write kda_encryptedkey");
_exit(0);
}
Expand All @@ -351,7 +351,7 @@ genkey(const char *pubkeyfile, struct diocskerneldump_arg *kdap)
err(1, "Unable to allocate encrypted key");
bytes = read(filedes[0], kdap->kda_encryptedkey,
kdap->kda_encryptedkeysize);
if (bytes != kdap->kda_encryptedkeysize)
if (bytes != (ssize_t)kdap->kda_encryptedkeysize)
errx(1, "genkey pipe read kda_encryptedkey");
error = waitpid(pid, &status, WEXITED);
if (error == -1)
Expand Down

0 comments on commit 080c6fd

Please sign in to comment.