Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/lib/libc/rpc CID 1338515: Make it clear that the pfd variabl...



details:   https://anonhg.NetBSD.org/src/rev/6884c5b291cd
branches:  trunk
changeset: 341529:6884c5b291cd
user:      christos <christos%NetBSD.org@localhost>
date:      Tue Nov 10 18:06:53 2015 +0000

description:
CID 1338515: Make it clear that the pfd variable can't be NULL

diffstat:

 lib/libc/rpc/svc_run.c |  6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diffs (27 lines):

diff -r 6baceeb23866 -r 6884c5b291cd lib/libc/rpc/svc_run.c
--- a/lib/libc/rpc/svc_run.c    Tue Nov 10 18:04:51 2015 +0000
+++ b/lib/libc/rpc/svc_run.c    Tue Nov 10 18:06:53 2015 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: svc_run.c,v 1.25 2015/11/07 23:09:20 christos Exp $    */
+/*     $NetBSD: svc_run.c,v 1.26 2015/11/10 18:06:53 christos Exp $    */
 
 /*
  * Copyright (c) 2010, Oracle America, Inc.
@@ -37,7 +37,7 @@
 static char *sccsid = "@(#)svc_run.c 1.1 87/10/13 Copyr 1984 Sun Micro";
 static char *sccsid = "@(#)svc_run.c   2.1 88/07/29 4.0 RPCSRC";
 #else
-__RCSID("$NetBSD: svc_run.c,v 1.25 2015/11/07 23:09:20 christos Exp $");
+__RCSID("$NetBSD: svc_run.c,v 1.26 2015/11/10 18:06:53 christos Exp $");
 #endif
 #endif
 
@@ -156,7 +156,7 @@
                        goto out;
                }
 
-               if (fdsize != svc_pollfd_getsize(0)) {
+               if (pdf == NULL || fdsize != svc_pollfd_getsize(0)) {
                        fdsize = svc_fdset_getsize(0);
                        free(pfd);
                        pfd = svc_pollfd_copy(svc_pollfd_get());



Home | Main Index | Thread Index | Old Index