Fixed printf format errors.

This commit is contained in:
Bruce Evans 1998-06-28 20:33:36 +00:00
parent 7fafc6f67c
commit 836b4a7ff9
3 changed files with 8 additions and 7 deletions

View File

@ -246,7 +246,7 @@ kmem_setup()
Lseek(kmem, (off_t)current_nl[X_DUMPLO].n_value, L_SET);
(void)Read(kmem, &dumplo, sizeof(dumplo));
if (verbose)
(void)printf("dumplo = %d (%d * %d)\n",
(void)printf("dumplo = %ld (%ld * %d)\n",
dumplo, dumplo/DEV_BSIZE, DEV_BSIZE);
Lseek(kmem, (off_t)current_nl[X_DUMPMAG].n_value, L_SET);
(void)Read(kmem, &dumpmag, sizeof(dumpmag));

View File

@ -42,7 +42,7 @@
#ifndef lint
static const char rcsid[] =
"$Id$";
"$Id: scsi.c,v 1.17 1998/01/12 07:57:57 charnier Exp $";
#endif /* not lint */
#include <ctype.h>
@ -378,9 +378,10 @@ do_cmd(int fd, char *fmt, int argc, char **argv)
err(1, "write");
}
else if (amount == 0)
fprintf(stderr, "Warning: wrote only %d bytes out of %d.\n",
scsireq->datalen - count,
scsireq->datalen);
fprintf(stderr,
"Warning: wrote only %lu bytes out of %lu.\n",
(u_long)scsireq->datalen - count,
(u_long)scsireq->datalen);
}
else

View File

@ -42,7 +42,7 @@ static char copyright[] =
#ifndef lint
/*static char sccsid[] = "from: @(#)slattach.c 4.6 (Berkeley) 6/1/90";*/
static char rcsid[] = "$Id: slattach.c,v 1.30 1998/01/25 09:16:55 jb Exp $";
static char rcsid[] = "$Id: slattach.c,v 1.31 1998/02/20 07:28:50 jb Exp $";
#endif /* not lint */
#include <sys/types.h>
@ -268,7 +268,7 @@ void acquire_line()
/* create PID file */
if((pidfile = fopen(pidfilename, "w"))) {
fprintf(pidfile, "%ld\n", getpid());
fprintf(pidfile, "%ld\n", (long)getpid());
fclose(pidfile);
}