[Thunar-dev] Compilation error with 26/05 snapshot

Benedikt Meurer benedikt.meurer at unix-ag.uni-siegen.de
Mon Jun 27 14:40:09 CEST 2005


Rodrigo Coacci wrote:
> Guys, after updating my libexo and compiling the snapshot, I get the 
> following error:
> 
> main.c:40: warning: 'file' might be used uninitialized in this function
> 
> It's in Thunar-main.
> Shall I initialize it or just disable -Werror?
> Or was something wrong I did?
> Has anybody tried this one yet?

Hm, interesting, my gcc never gave that warning, I guess you're using an 
older version. Because the compiler should be able to see that file can 
only be ever accessed if uri != NULL. Anyways, replace line 40 with

  ThunarFile *file = NULL;

and things should work.

> Abraços,
>       Rodrigo

HTH,
Benedikt



More information about the Thunar-dev mailing list