Re: [gtk-vnc-devel] [patch] boolean functions must return FALSE on failure



On Wed, Aug 01, 2007 at 01:57:45PM -0300, Jonh Wendell wrote:
> Hi. This patch changes behavior of boolean functions in gvnc.c (which
> uses gvnc_has_error() ) to return FALSE (instead of TRUE) in case of
> failure. 
> 
> I think it's better to read (and understand):
> if (!gvnc_initialize())
>   handle_error();
> 
> than:
> if (gvnc_initialize())
>   handle_error();
> 
> What do you think?

Yeah, I think this would make things a little less confusing. 

Dan.
-- 
|=- Red Hat, Engineering, Emerging Technologies, Boston.  +1 978 392 2496 -=|
|=-           Perl modules: http://search.cpan.org/~danberr/              -=|
|=-               Projects: http://freshmeat.net/~danielpb/               -=|
|=-  GnuPG: 7D3B9505   F3C9 553F A1DA 4AC2 5648 23C1 B3DF F742 7D3B 9505  -=| 




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