rpc.tlsservd: Check for a tls syscall failure.
Although the tls syscall to set up the upcall should not normally fail, the daemon should check for such a failure. This patch adds a check for that failure. MFC after: 1 week
This commit is contained in:
parent
2eee99f794
commit
ab3c59a107
@ -402,7 +402,16 @@ main(int argc, char **argv)
|
|||||||
rpctls_gothup = false;
|
rpctls_gothup = false;
|
||||||
LIST_INIT(&rpctls_ssllist);
|
LIST_INIT(&rpctls_ssllist);
|
||||||
|
|
||||||
rpctls_syscall(RPCTLS_SYSC_SRVSETPATH, rpctls_sockname[mypos]);
|
if (rpctls_syscall(RPCTLS_SYSC_SRVSETPATH, rpctls_sockname[mypos]) < 0){
|
||||||
|
if (rpctls_debug_level == 0) {
|
||||||
|
syslog(LOG_ERR,
|
||||||
|
"Can't set upcall socket path=%s errno=%d",
|
||||||
|
rpctls_sockname[mypos], errno);
|
||||||
|
exit(1);
|
||||||
|
}
|
||||||
|
err(1, "Can't set upcall socket path=%s",
|
||||||
|
rpctls_sockname[mypos]);
|
||||||
|
}
|
||||||
|
|
||||||
rpctls_svc_run();
|
rpctls_svc_run();
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user