mirror of
				https://github.com/tmux/tmux.git
				synced 2025-10-26 12:27:15 +00:00 
			
		
		
		
	POSIX only guarantees uname() will return a non-negative value on
success. ok nicm@
This commit is contained in:
		| @@ -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, "pid %ld, started %s", (long) getpid(), tim); | ||||||
| 	ctx->print( | 	ctx->print( | ||||||
| 	    ctx, "socket path %s, debug level %d", socket_path, debug_level); | 	    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", | 		ctx->print(ctx, "system is %s %s %s %s", | ||||||
| 		    un.sysname, un.release, un.version, un.machine); | 		    un.sysname, un.release, un.version, un.machine); | ||||||
| 	} | 	} | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user
	 Matthew Dempsky
					Matthew Dempsky