diff options
author | Craig Rodrigues <rodrigc@FreeBSD.org> | 2005-11-21 22:51:16 +0000 |
---|---|---|
committer | Craig Rodrigues <rodrigc@FreeBSD.org> | 2005-11-21 22:51:16 +0000 |
commit | f2bccf4766a1a2af94bda914f491835a019349cd (patch) | |
tree | f8b5d3b47fc5edbba861da56a1d801bfb4a719e9 /sbin/mount_nullfs/mount_nullfs.c | |
parent | aed0e2071fac86932d117ca387f6fa74c1db20e7 (diff) |
Bring mount_nullfs up to WARNS=6.
Notes
Notes:
svn path=/head/; revision=152670
Diffstat (limited to 'sbin/mount_nullfs/mount_nullfs.c')
-rw-r--r-- | sbin/mount_nullfs/mount_nullfs.c | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/sbin/mount_nullfs/mount_nullfs.c b/sbin/mount_nullfs/mount_nullfs.c index 410562469172..a0ad5f681908 100644 --- a/sbin/mount_nullfs/mount_nullfs.c +++ b/sbin/mount_nullfs/mount_nullfs.c @@ -66,9 +66,7 @@ int subdir(const char *, const char *); static void usage(void) __dead2; int -main(argc, argv) - int argc; - char *argv[]; +main(int argc, char *argv[]) { struct iovec iov[6]; int ch, mntflags; @@ -99,15 +97,15 @@ main(argc, argv) errx(EX_USAGE, "%s (%s) and %s are not distinct paths", argv[0], target, argv[1]); - iov[0].iov_base = "fstype"; + iov[0].iov_base = strdup("fstype"); iov[0].iov_len = sizeof("fstype"); - iov[1].iov_base = "nullfs"; + iov[1].iov_base = strdup("nullfs"); iov[1].iov_len = strlen(iov[1].iov_base) + 1; - iov[2].iov_base = "fspath"; + iov[2].iov_base = strdup("fspath"); iov[2].iov_len = sizeof("fspath"); iov[3].iov_base = source; iov[3].iov_len = strlen(source) + 1; - iov[4].iov_base = "target"; + iov[4].iov_base = strdup("target"); iov[4].iov_len = sizeof("target"); iov[5].iov_base = target; iov[5].iov_len = strlen(target) + 1; |