diff options
author | eadler <eadler@FreeBSD.org> | 2012-02-10 00:53:39 +0000 |
---|---|---|
committer | eadler <eadler@FreeBSD.org> | 2012-02-10 00:53:39 +0000 |
commit | a1ee9b22b34d2590cc596f0d4734db891d6def54 (patch) | |
tree | 84cca856f9cd0f98ddfb33c3bf1ea7e57b76546b /usr.sbin | |
parent | 956d09353b3831c6d61a9eee9ce9572333b1e8ed (diff) | |
download | FreeBSD-src-a1ee9b22b34d2590cc596f0d4734db891d6def54.zip FreeBSD-src-a1ee9b22b34d2590cc596f0d4734db891d6def54.tar.gz |
Fix r231300: Use correct test so we only bail out on error instead of on non-error.
Also, fix a style bug.
Submitted by: ache
Approved by: cperciva
MFC after: 1 month
Diffstat (limited to 'usr.sbin')
-rw-r--r-- | usr.sbin/pkg_install/create/perform.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/usr.sbin/pkg_install/create/perform.c b/usr.sbin/pkg_install/create/perform.c index bfe4ac4..4409551 100644 --- a/usr.sbin/pkg_install/create/perform.c +++ b/usr.sbin/pkg_install/create/perform.c @@ -216,7 +216,7 @@ pkg_perform(char **pkgs) /* Prefix should add an @cwd to the packing list */ if (Prefix) { char resolved_prefix[PATH_MAX]; - if (realpath(Prefix, resolved_prefix) != 0) + if (realpath(Prefix, resolved_prefix) == NULL) err(EXIT_FAILURE, "couldn't resolve path for prefix: %s", Prefix); add_plist_top(&plist, PLIST_CWD, resolved_prefix); } |