Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/usr.sbin/mtree Adjust test, we only want to return the struc...
details: https://anonhg.NetBSD.org/src/rev/0a9a2610f6a2
branches: trunk
changeset: 445972:0a9a2610f6a2
user: sevan <sevan%NetBSD.org@localhost>
date: Sun Nov 18 23:03:36 2018 +0000
description:
Adjust test, we only want to return the structure member if the result is not NULL.
Heads up by Sascha Wildner @ DragonFly BSD.
diffstat:
usr.sbin/mtree/create.c | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
diffs (27 lines):
diff -r 1092962a2d21 -r 0a9a2610f6a2 usr.sbin/mtree/create.c
--- a/usr.sbin/mtree/create.c Sun Nov 18 22:53:22 2018 +0000
+++ b/usr.sbin/mtree/create.c Sun Nov 18 23:03:36 2018 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: create.c,v 1.75 2017/12/31 03:04:44 christos Exp $ */
+/* $NetBSD: create.c,v 1.76 2018/11/18 23:03:36 sevan Exp $ */
/*-
* Copyright (c) 1989, 1993
@@ -38,7 +38,7 @@
#if 0
static char sccsid[] = "@(#)create.c 8.1 (Berkeley) 6/6/93";
#else
-__RCSID("$NetBSD: create.c,v 1.75 2017/12/31 03:04:44 christos Exp $");
+__RCSID("$NetBSD: create.c,v 1.76 2018/11/18 23:03:36 sevan Exp $");
#endif
#endif /* not lint */
@@ -117,7 +117,7 @@
host[sizeof(host) - 1] = '\0';
if ((user = getlogin()) == NULL) {
struct passwd *pw;
- user = (pw = getpwuid(getuid())) == NULL ? pw->pw_name :
+ user = (pw = getpwuid(getuid())) != NULL ? pw->pw_name :
"<unknown>";
}
Home |
Main Index |
Thread Index |
Old Index