svn commit: r287348 - head/lib/libc/rpc
Craig Rodrigues
rodrigc at FreeBSD.org
Tue Sep 1 07:33:37 UTC 2015
Author: rodrigc
Date: Tue Sep 1 07:33:36 2015
New Revision: 287348
URL: https://svnweb.freebsd.org/changeset/base/287348
Log:
Use correct function prototype for signal handler.
Eliminates gcc 4.9 warning.
Modified:
head/lib/libc/rpc/auth_time.c
Modified: head/lib/libc/rpc/auth_time.c
==============================================================================
--- head/lib/libc/rpc/auth_time.c Tue Sep 1 07:32:03 2015 (r287347)
+++ head/lib/libc/rpc/auth_time.c Tue Sep 1 07:33:36 2015 (r287348)
@@ -255,7 +255,7 @@ __rpc_get_time_offset(struct timeval *td
char ut[64], ipuaddr[64];
endpoint teps[32];
nis_server tsrv;
- void (*oldsig)() = NULL; /* old alarm handler */
+ void (*oldsig)(int) = NULL; /* old alarm handler */
struct sockaddr_in sin;
socklen_t len;
int s = RPC_ANYSOCK;
@@ -424,7 +424,7 @@ __rpc_get_time_offset(struct timeval *td
} else {
int res;
- oldsig = (void (*)())signal(SIGALRM, alarm_hndler);
+ oldsig = (void (*)(int))signal(SIGALRM, alarm_hndler);
saw_alarm = 0; /* global tracking the alarm */
alarm(20); /* only wait 20 seconds */
res = _connect(s, (struct sockaddr *)&sin, sizeof(sin));
More information about the svn-src-head
mailing list