aboutsummaryrefslogtreecommitdiffstats
path: root/sbin/mdmfs
diff options
context:
space:
mode:
authorSuleiman Souhlal <ssouhlal@FreeBSD.org>2005-01-25 14:28:31 +0000
committerSuleiman Souhlal <ssouhlal@FreeBSD.org>2005-01-25 14:28:31 +0000
commit6449237fe684b89033d2ded0e1885ceb379ed8c4 (patch)
tree7c277a769742ce3e551b98f3ba039b775ed23bda /sbin/mdmfs
parente65b439414e6885ee5087f6e820315e0be91e661 (diff)
downloadsrc-6449237fe684b89033d2ded0e1885ceb379ed8c4.tar.gz
src-6449237fe684b89033d2ded0e1885ceb379ed8c4.zip
- Make WARNS?= 6 clean
- Add WARNS?= 6 Approved by: stefanf, grehan (mentor)
Notes
Notes: svn path=/head/; revision=140815
Diffstat (limited to 'sbin/mdmfs')
-rw-r--r--sbin/mdmfs/Makefile1
-rw-r--r--sbin/mdmfs/mdmfs.c5
2 files changed, 4 insertions, 2 deletions
diff --git a/sbin/mdmfs/Makefile b/sbin/mdmfs/Makefile
index 999793f0e103..1ef708454267 100644
--- a/sbin/mdmfs/Makefile
+++ b/sbin/mdmfs/Makefile
@@ -4,5 +4,6 @@ PROG= mdmfs
LINKS= ${BINDIR}/${PROG} ${BINDIR}/mount_mfs
MAN= mdmfs.8
MLINKS+= mdmfs.8 mount_mfs.8
+WARNS?= 6
.include <bsd.prog.mk>
diff --git a/sbin/mdmfs/mdmfs.c b/sbin/mdmfs/mdmfs.c
index bed6dc776e00..d276dc01f5e1 100644
--- a/sbin/mdmfs/mdmfs.c
+++ b/sbin/mdmfs/mdmfs.c
@@ -101,6 +101,7 @@ main(int argc, char **argv)
softdep = true;
autounit = false;
have_mdtype = false;
+ mdtype = MD_SWAP;
mdname = MD_NAME;
mdnamelen = strlen(mdname);
/*
@@ -251,7 +252,7 @@ main(int argc, char **argv)
unit = -1;
} else {
unit = strtoul(unitstr, &p, 10);
- if (unit == (unsigned)ULONG_MAX || *p != '\0')
+ if ((unsigned)unit == (unsigned)ULONG_MAX || *p != '\0')
errx(1, "bad device unit: %s", unitstr);
}
@@ -399,7 +400,7 @@ do_mdconfig_attach_au(const char *args, const enum md_types mdtype)
strncpy(linebuf, linep + mdnamelen, linelen);
linebuf[linelen] = '\0';
unit = strtoul(linebuf, &p, 10);
- if (unit == (unsigned)ULONG_MAX || *p != '\n')
+ if ((unsigned)unit == (unsigned)ULONG_MAX || *p != '\n')
errx(1, "unexpected output from mdconfig (attach)");
fclose(sfd);