bug-cfengine
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Buffer size mismatch


From: Mark Burgess
Subject: Re: Buffer size mismatch
Date: Sat, 6 Nov 2004 06:53:51 +0100
User-agent: Mutt/1.4.2i

On Fri, Nov 05, 2004 at 01:34:48PM -0600, Chip Seraphine wrote:
> in 2.1.11, I get the following error  when compiling cfenvgraph 
> (gcc,solaris2.9,i386):
> 
> ld: warning: symbol `VFQNAME' has differing sizes:
>        (file cfenvgraph.o value=0x1000; file globals.o value=0x400);
>        cfenvgraph.o definition taken
> 
> Grepping around, I see:
> 
> cf.extern.h:228:extern char VFQNAME[];
> cfenvgraph.c:85:char VFQNAME[CF_BUFSIZE];
> globals.c:375: PROTECTED char       VFQNAME[CF_MAXVARSIZE];
> 
> The last two concern me:
> address@hidden:32:18-..gine-2.1.11.i386/src$ grep 'define 
> CF_MAXVARSIZE' *.h
> cf.defs.h:#define CF_MAXVARSIZE 1024
> 
> address@hidden:32:20-..gine-2.1.11.i386/src$ grep 'define CF_BUFSIZE' *.h
> cf.defs.h:#define CF_BUFSIZE 4096
> 
> whoops!
> 
> I would guess that CF_MAXVARSIZE' should maybe be replaced with 
> CF_BUFSIZE in all occurances?  (Or at least #defined to it?)  Or is 

No!

> VFQNAME in cfenvgraph.c a totally different variable that just happened 
> to collide with a global, and it should maybe be renamed?

They are independent, but used for the same thing. Better to
redefine the size in cfenvgraph.c so that it is consistent.

This is nothing at all to worry about

Mark

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Work: +47 22453272            Email:  address@hidden
Fax : +47 22453205            WWW  :  http://www.iu.hio.no/~mark
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~





reply via email to

[Prev in Thread] Current Thread [Next in Thread]