dumpon: fix build on some architectures

Fix a -Wsign-compare issue on some architectures.

Fixes:		96f9bd4654
Pointy hat to:	me
MFC after:	1 week
Sponsored by:	Dell EMC Isilon
This commit is contained in:
Eric van Gyzen 2021-08-11 21:27:24 -05:00
parent a3ff18e271
commit 080c6fdc0c

View File

@ -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);
}
@ -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)