[Bro-Dev] fixing compiler warnings

Seth Hall seth at icir.org
Fri Jan 21 13:44:39 PST 2011


On Jan 20, 2011, at 8:33 PM, Gregor Maier wrote:

> On 1/20/11 12:12 , Seth Hall wrote:
>> 
>> [ 36%] Building CXX object src/CMakeFiles/bro.dir/main.cc.o
>> /Users/seth/bro/bro.git/src/main.cc: In function ‘int main(int, char**)’:
>> /Users/seth/bro/bro.git/src/main.cc:415: warning: deprecated conversion from string constant to ‘char*’
> 
> int main(int argc, char *argv[])
> might to the trick....

That was my first inclination too, but the error isn't on that line. :)

> -internal_error(msg);
> +internal_error("%s", msg);

Oh!  Of course.

> On a different note wrt to integer format string warnings: These
> warnings tend to creep back in whenever you compile on a different
> platform that has different integers widths. AFAIK the only way to get
> really rid of them for good is to use the macros from inttypes.h
> But that's already flagged for the integer types cleanup in ticket #319

I'm pretty clueless about the course of action that needs to happen for ticket #319.  Could you give some guidance?  Maybe I could go ahead and do it sometime if I knew what needs done.

  .Seth


More information about the bro-dev mailing list