Sophie

Sophie

distrib > Mageia > 6 > armv5tl > media > core-release-src > by-pkgid > 86d02c6716e421acdde40e1f95bd1d59 > files > 26

netcat-traditional-1.10-40.mga6.src.rpm

Summary: Always use getservbyport.
Contributor: Decklin Foster <decklin@red-bean.com>

Index: netcat-1.10/netcat.c
===================================================================
--- netcat-1.10.orig/netcat.c	2006-03-24 12:26:39.000000000 -0500
+++ netcat-1.10/netcat.c	2006-03-24 12:26:40.000000000 -0500
@@ -462,8 +462,10 @@
     if (pstring)			/* one or the other, pleeze */
       return (0);
     x = pnum;
-    if (o_nflag)			/* go faster, skip getservbyblah */
-      goto gp_finish;
+    /* disabled, see bug #98902. if this is *really* slowing someone
+     * down I'll reconsider. */
+    /* if (o_nflag) */			/* go faster, skip getservbyblah */
+      /* goto gp_finish; */
     y = htons (x);			/* gotta do this -- see Fig.1 below */
     servent = getservbyport (y, whichp);
     if (servent) {