Ethereal-users: [ethereal-users] Bug in ethereal-0.7.6 + patch

Note: This archive is from the project's previous web site, ethereal.com. This list is no longer active.

From: Joe Clarke <jclarke@xxxxxxxxx>
Date: Wed, 27 Oct 1999 16:24:55 -0400 (EDT)
I found a null pointer bug in ethereal-0.7.6.  It seems you call
val_to_str with a fmt pointing to NULL.  I patched this to be a dummy
value (i.e. "foo") to avoid the seg fault.  I found this on FreeBSD
3.3-RELEASE.  Hope this helps.

Joe Clarke

-- 
Joe Clarke, CE                     |          |
Customer Support Engineer        |||||      |||||
Phone: (919) 392-2867       ..:|||||||||::|||||||||:..
Email: jclarke@xxxxxxxxx     c i s c o  S y s t e m s

----------------------------------------------------------------------------

*** ipproto.c.orig	Wed Oct 27 16:19:12 1999
--- ipproto.c	Wed Oct 27 16:19:34 1999
***************
*** 98,104 ****
      struct protoent *pe;
  #endif
  
!     if ((s = val_to_str(proto, ipproto_val, NULL)) != NULL)
  	goto ok;
  
  #ifdef HAVE_GETPROTOBYNUMBER
--- 98,104 ----
      struct protoent *pe;
  #endif
  
!     if ((s = val_to_str(proto, ipproto_val, "foo")) != NULL)
  	goto ok;
  
  #ifdef HAVE_GETPROTOBYNUMBER