Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F149914734
D28478.id83828.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
836 B
Referenced Files
None
Subscribers
None
D28478.id83828.diff
View Options
diff --git a/contrib/netbsd-tests/lib/libc/rpc/t_rpc.c b/contrib/netbsd-tests/lib/libc/rpc/t_rpc.c
--- a/contrib/netbsd-tests/lib/libc/rpc/t_rpc.c
+++ b/contrib/netbsd-tests/lib/libc/rpc/t_rpc.c
@@ -72,11 +72,21 @@
*/
tv.tv_sec = 0;
tv.tv_usec = 500000;
+#ifdef __FreeBSD__
+ /*
+ * FreeBSD does not allow setting the timeout using __rpc_control,
+ * but does have clnt_create_timed() that allows passing a timeout.
+ */
+ if ((clnt = clnt_create_timed(host, RPCBPROG, RPCBVERS, transp,
+ &tv)) == NULL)
+ SKIPX(, "clnt_create (%s)", clnt_spcreateerror(""));
+#else
#define CLCR_SET_RPCB_TIMEOUT 2
__rpc_control(CLCR_SET_RPCB_TIMEOUT, &tv);
if ((clnt = clnt_create(host, RPCBPROG, RPCBVERS, transp)) == NULL)
SKIPX(, "clnt_create (%s)", clnt_spcreateerror(""));
+#endif
tv.tv_sec = 1;
tv.tv_usec = 0;
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sun, Mar 29, 2:17 AM (7 h, 14 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
30504538
Default Alt Text
D28478.id83828.diff (836 B)
Attached To
Mode
D28478: lib/libc/tests/rpc: Correctly set timeout
Attached
Detach File
Event Timeline
Log In to Comment