From 795549aafbb0eebddcdd17437e776383145e02cb Mon Sep 17 00:00:00 2001 From: John Hood Date: Sun, 6 Nov 2016 05:57:09 -0500 Subject: [PATCH] OpenIndiana pid_t is long int --- src/frontend/mosh-server.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/frontend/mosh-server.cc b/src/frontend/mosh-server.cc index 4bf1294..1022a34 100644 --- a/src/frontend/mosh-server.cc +++ b/src/frontend/mosh-server.cc @@ -480,7 +480,7 @@ static int run_server( const char *desired_ip, const char *desired_port, } char utmp_entry[ 64 ] = { 0 }; - snprintf( utmp_entry, 64, "mosh [%d]", getpid() ); + snprintf( utmp_entry, 64, "mosh [%ld]", static_cast( getpid() ) ); /* Fork child process */ pid_t child = forkpty( &master, NULL, NULL, &window_size );