summaryrefslogtreecommitdiff
path: root/usr.bin/tmux
diff options
context:
space:
mode:
authorMatthew Dempsky <matthew@cvs.openbsd.org>2011-04-19 20:12:48 +0000
committerMatthew Dempsky <matthew@cvs.openbsd.org>2011-04-19 20:12:48 +0000
commit37d14446486e1d383e94bcf44787d54e5bb0af92 (patch)
treede4635c267d05f5158e21a51338f64ed9a16738f /usr.bin/tmux
parenta684a49eb545be20fb174482be2c8d3a22b132f8 (diff)
POSIX only guarantees uname() will return a non-negative value on
success. ok nicm@
Diffstat (limited to 'usr.bin/tmux')
-rw-r--r--usr.bin/tmux/cmd-server-info.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.bin/tmux/cmd-server-info.c b/usr.bin/tmux/cmd-server-info.c
index d9e7b747b05..f734129eade 100644
--- a/usr.bin/tmux/cmd-server-info.c
+++ b/usr.bin/tmux/cmd-server-info.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: cmd-server-info.c,v 1.24 2011/01/26 01:54:56 nicm Exp $ */
+/* $OpenBSD: cmd-server-info.c,v 1.25 2011/04/19 20:12:47 matthew Exp $ */
/*
* Copyright (c) 2008 Nicholas Marriott <nicm@users.sourceforge.net>
@@ -71,7 +71,7 @@ cmd_server_info_exec(unused struct cmd *self, struct cmd_ctx *ctx)
ctx->print(ctx, "pid %ld, started %s", (long) getpid(), tim);
ctx->print(
ctx, "socket path %s, debug level %d", socket_path, debug_level);
- if (uname(&un) == 0) {
+ if (uname(&un) >= 0) {
ctx->print(ctx, "system is %s %s %s %s",
un.sysname, un.release, un.version, un.machine);
}