[Snort-users] SIOCGIFMTU fix

Martin Roesch roesch at ...421...
Fri Jan 12 14:42:49 EST 2001


Interesting, it compiled without complaint on my system (which it
shouldn't have).  Here's a patch for the patch :)

--- snort.c.orig        Fri Jan 12 14:34:00 2001
+++ snort.c     Fri Jan 12 14:35:14 2001
@@ -1487,7 +1487,10 @@
     if (ioctl(fd, SIOCGIFMTU, &ifr) == 0)
         retval = ifr.ifr_metric;
 #else
-    retval = ETHERNET_MTU;
+    if(1)
+    {
+        retval = ETHERNET_MTU;
+    }
 #endif
 #else
     if (ioctl(fd, SIOCRIPMTU, &ifr) == 0)



Ralf Hildebrandt wrote:
> 
> On Fri, Jan 12, 2001 at 12:13:51PM -0500, Martin Roesch wrote:
> > Hi guys, here's a temporary fix for the SIO* mess.  I'll be checking
> > this into CVS shortly.
> 
> Doesn't work. It totally fucks up:
> .
> .
> .
> snort.c: In function ParseCmdLine':
> snort.c:868: warning: implicit declaration of function snprintf'
> snort.c: In function GetIfrMTU':
> snort.c:1496: parse error before else'
> make: *** [snort.o] Error 1
> 
> --
> ralf.hildebrandt at ...821...
> System Engineer                                            innominate AG
> Diplom-Informatiker                                 the linux architects
> tel: +49.30.308806-62  fax: -698                      www.innominate.com
> 
>   ------------------------------------------------------------------------
>    Part 1.2Type: application/pgp-signature




More information about the Snort-users mailing list