Revision: 48391
          http://brlcad.svn.sourceforge.net/brlcad/?rev=48391&view=rev
Author:   starseeker
Date:     2012-01-11 16:04:09 +0000 (Wed, 11 Jan 2012)
Log Message:
-----------
service shouldn't be null with pkg_permserver - just check for it up front.  
CID 257

Modified Paths:
--------------
    brlcad/trunk/src/libpkg/pkg.c

Modified: brlcad/trunk/src/libpkg/pkg.c
===================================================================
--- brlcad/trunk/src/libpkg/pkg.c       2012-01-11 15:46:11 UTC (rev 48390)
+++ brlcad/trunk/src/libpkg/pkg.c       2012-01-11 16:04:09 UTC (rev 48391)
@@ -534,6 +534,7 @@
 {
     struct servent *sp;
     int pkg_listenfd;
+    if (service == NULL) return (int)PKC_ERROR;
 #ifdef HAVE_WINSOCK_H
     SOCKADDR_IN saServer;
     WORD wVersionRequested;            /* initialize Windows socket 
networking, increment reference count */
@@ -615,7 +616,7 @@
     memset((char *)&sinme, 0, sizeof(sinme));
 
 #  ifdef HAVE_SYS_UN_H
-    if (service != NULL && service[0] == '/') {
+    if (service[0] == '/') {
        /* UNIX Domain socket */
        strncpy(sunme.sun_path, service, sizeof(sunme.sun_path));
        sunme.sun_family = AF_UNIX;

This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.


------------------------------------------------------------------------------
Ridiculously easy VDI. With Citrix VDI-in-a-Box, you don't need a complex
infrastructure or vast IT resources to deliver seamless, secure access to
virtual desktops. With this all-in-one solution, easily deploy virtual 
desktops for less than the cost of PCs and save 60% on VDI infrastructure 
costs. Try it free! http://p.sf.net/sfu/Citrix-VDIinabox
_______________________________________________
BRL-CAD Source Commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/brlcad-commits

Reply via email to