Ethereal-cvs: Re: [ethereal-cvs] cvs commit: ethereal proto.c

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

From: Laurent Deniel <deniel@xxxxxxxxxxx>
Date: Thu, 10 Aug 2000 22:03:10 +0200
Guy Harris wrote:
> 
> guy         2000/08/10 14:41:49 CDT
> 
>   Modified files:
>     .                    proto.c
>   Log:
>   We must include "snprintf.h" *after* including <stdarg.h>, and
>   <stdarg.h> is now included by "proto.h", so we must include "snprintf.h"
>   after including "proto.h".
> 
>   Revision  Changes    Path
>   1.75      +5 -5      ethereal/proto.c

This is simply stupid.

1) in almost all other source code, there is :

#ifdef NEED_SNPRINTF_H
# ifdef HAVE_STDARG_H
#  include <stdarg.h>
# else
#  include <varargs.h>
# endif
# include "snprintf.h"
#endif

2) if a service (i.e. snprintf) can not be used without including
   some other header files, why not simply add 

# ifdef HAVE_STDARG_H
#  include <stdarg.h>
# else
#  include <varargs.h>
# endif

in our snprintf.h file ?

--
Laurent DENIEL        | E-mail: deniel@xxxxxxxxxxx
Paris, FRANCE         |         laurent.deniel@xxxxxxxxxxxxxxxxxxxxxxxxxxxx
                      | WWW   : http://www.worldnet.fr/~deniel
    All above opinions are personal, unless stated otherwise.