diff options
| author | enami <enami@NetBSD.org> | 2000-10-10 14:30:40 +0000 |
|---|---|---|
| committer | enami <enami@NetBSD.org> | 2000-10-10 14:30:40 +0000 |
| commit | e92c3f2867ac507a9a46ab2b707f78ce2a6cf658 (patch) | |
| tree | f449732530b9d517561557674e3dc8c9401aa8ed /usr.bin/mkfifo | |
| parent | d4f8f51f40b48b9c18bc1561ecb99daae66eff79 (diff) | |
- The type of return value of setmode is a void * and getmode takes it,
rather than mode_t *.
- Free the storage allocated by setmode unless it is obvious that program
exits immediately.
Diffstat (limited to 'usr.bin/mkfifo')
| -rw-r--r-- | usr.bin/mkfifo/mkfifo.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/usr.bin/mkfifo/mkfifo.c b/usr.bin/mkfifo/mkfifo.c index 6bd45b0dfdd..9fd4686ebde 100644 --- a/usr.bin/mkfifo/mkfifo.c +++ b/usr.bin/mkfifo/mkfifo.c @@ -1,4 +1,4 @@ -/* $NetBSD: mkfifo.c,v 1.8 1997/10/19 05:11:54 lukem Exp $ */ +/* $NetBSD: mkfifo.c,v 1.9 2000/10/10 14:30:41 enami Exp $ */ /* * Copyright (c) 1990, 1993 @@ -43,7 +43,7 @@ __COPYRIGHT("@(#) Copyright (c) 1990, 1993\n\ #if 0 static char sccsid[] = "@(#)mkfifo.c 8.2 (Berkeley) 1/5/94"; #endif -__RCSID("$NetBSD: mkfifo.c,v 1.8 1997/10/19 05:11:54 lukem Exp $"); +__RCSID("$NetBSD: mkfifo.c,v 1.9 2000/10/10 14:30:41 enami Exp $"); #endif /* not lint */ #include <stdio.h> @@ -65,7 +65,7 @@ main(argc, argv) char *argv[]; { int ch, exitval; - void * set; + void *set; mode_t mode; setlocale (LC_ALL, ""); @@ -85,7 +85,8 @@ main(argc, argv) /* In symbolic mode strings, the + and - operators are interpreted relative to an assumed initial mode of a=rw. */ - mode = getmode (set, 0666); + mode = getmode(set, 0666); + free(set); break; case '?': default: |
