[PATCH] mostly clang warnings

Andreas Schneider asn at samba.org
Tue Oct 18 16:12:25 UTC 2016


On Tuesday, 18 October 2016 16:25:26 CEST Volker Lendecke wrote:

Hi Volker,

the patchset looks fine for me.

> -       if (h1.data) {
> +       if (h1.data[0] || h1.data[1]) {

I prefer to write:

if (h1.data[0] != '\0' || h1.data[1] != '\0') {
  ...
}

When reading the code the it makes it more clear what we are checking for.

I'm fine if you push it as is, but would prefer it the way I did it above.


Cheers,


	-- andreas


-- 
Andreas Schneider                   GPG-ID: CC014E3D
Samba Team                             asn at samba.org
www.samba.org



More information about the samba-technical mailing list