]> The Tcpdump Group git mirrors - tcpdump/blobdiff - missing/getservent.c
Handle rpcaps:// URLs as well, for rpcap-over-TLS.
[tcpdump] / missing / getservent.c
index 48b7465ca2be243fd8e1845f9f719aa2177e9b2b..198644f244036cdc18ade9b027f156eeca9673c1 100644 (file)
@@ -35,7 +35,7 @@
  */
 
 #ifdef HAVE_CONFIG_H
-#include "config.h"
+#include <config.h>
 #endif
 
 #include <netdissect-stdinc.h>
@@ -65,9 +65,9 @@ const char *etc_path(const char *file)
         return (file);
     else
 #ifdef _WIN32
-    snprintf(path, sizeof(path), "%s%s%s", env, __PATH_ETC_INET, file);
+    nd_snprintf(path, sizeof(path), "%s%s%s", env, __PATH_ETC_INET, file);
 #else
-    snprintf(path, sizeof(path), "%s%s", env, file);
+    nd_snprintf(path, sizeof(path), "%s%s", env, file);
 #endif
     return (path);
 }
@@ -96,7 +96,7 @@ struct servent *
 getservent(void)
 {
     char *p;
-    register char *cp, **q;
+    char *cp, **q;
 
     if (servf == NULL && (servf = fopen(etc_path(__PATH_SERVICES), "r")) == NULL)
         return (NULL);