From: Roger Dingledine Date: Fri, 19 Mar 2004 21:34:04 +0000 (+0000) Subject: getpid returns a pid_t. we all know that's an int. but solaris doesn't know. X-Git-Tag: tor-0.0.3~30 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=df3f37b84f81ec7757e056ff82530ef6e863fb95;p=thirdparty%2Ftor.git getpid returns a pid_t. we all know that's an int. but solaris doesn't know. svn:r1305 --- diff --git a/src/common/util.c b/src/common/util.c index 77e7916d86..b95b23d8f2 100644 --- a/src/common/util.c +++ b/src/common/util.c @@ -837,7 +837,7 @@ void write_pidfile(char *filename) { log_fn(LOG_WARN, "unable to open %s for writing: %s", filename, strerror(errno)); } else { - fprintf(pidfile, "%d", getpid()); + fprintf(pidfile, "%d", (int)getpid()); fclose(pidfile); } #endif