Ethereal-dev: Re: [Ethereal-dev] Re: [patch] SNMP MIB module list

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

From: Jaap Keuter <jaap.keuter@xxxxxxxxx>
Date: Tue, 16 Aug 2005 00:00:28 +0200 (CEST)
On Mon, 15 Aug 2005, Wes Hardaker wrote:

> >>>>> On Wed, 10 Aug 2005 23:39:01 +0200 (CEST), Jaap Keuter <jaap.keuter@xxxxxxxxx> said:
>
> >> > Shouldn't the SNMP dissector substitute the colon by a semicolon on the
> >> > Win32 platform so that the translations work and a save fixes the
> >> > preferences file?
> >>
> >> There's a related comment in epan/dissectors/packet-snmp.c saying
> >>
> >> /* Default MIB modules to load */
> >> /*
> >> * XXX - Should we try to be clever and replace colons for semicolons under
> >> * Windows and the converse on non-Windows systems?
> >> */
> >>
> >> It looks like just noone has found the time/motivation to implement this
> >> yet. Patches appreciated. :-)
>
> Jaap> Ok, had some time to look into it. This is what I found:
>
> Err....
>
> This is from the net-snmp net-snmp-config.h file:
>
>   #if defined (WIN32) || defined (mingw32) || defined (cygwin)
>   #define ENV_SEPARATOR ";"
>   #define ENV_SEPARATOR_CHAR ';'
>   #else
>   #define ENV_SEPARATOR ":"
>   #define ENV_SEPARATOR_CHAR ':'
>   #endif
>
> Which means it should be doing this for you anyway, no (unless
> net-snmp wasn't built properly)?

Yeah, it should be doing this. And it does, really. But it hasn't always
done so in the past and that is where the trouble starts.

If you read back to my original post, I've mentioned that upgrading
ethereal doesn't fix an (in this matter) incorrect preference file. So
even though the new code does it's job correctly it still has to account
for 'old style' preference files. This patch does exactly that.

Thanx,
Jaap