Samba4, latest build fails: wrong int and long int casts

steve steve at steve-ss.com
Wed Aug 1 07:06:08 MDT 2012


On 08/01/2012 02:19 PM, steve wrote:
> Ubuntu 12.04
>
> [2493/4244] Compiling source4/heimdal/lib/com_err/error.c
> ../source4/heimdal/lib/com_err/error.c: In function ‘com_right_r’:
> ../source4/heimdal/lib/com_err/error.c:68:6: error: format ‘%d’ 
> expects argument of type ‘int’, but argument 4 has type ‘long int’ 
> [-Werror=format]

Casting to (int) cast works:
68 snprintf(domain, sizeof(domain), "heim_com_err%d",(int) p->table->base);
hth
Cheers,
Steve




More information about the samba-technical mailing list