Need some help fixing a warning

Kai Blin kai at samba.org
Wed Dec 26 09:25:11 GMT 2007


Hi folks,

I'm currently trying to fix the following warning:
libnet/libnet_domain.c:848: warning: passing argument 1 of ‘talloc_free’ 
discards qualifiers from pointer target type

This like is trying to free the samr.name from the libnet context, which is a 
const pointer. It's set on line 365 by a talloc_steal over from the 
domain_open_samr_state struct's domain_name lsa_String.

An lsa_String contains a const char* pointer, talloc_steal doesn't dump the 
const qualifier, and talloc_free doesn't cope with possible const pointers.

Where do I start fixing that one?

Cheers,
Kai

-- 
Kai Blin
WorldForge developer  http://www.worldforge.org/
Wine developer        http://wiki.winehq.org/KaiBlin
Samba team member     http://www.samba.org/samba/team/
--
Will code for cotton.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part.
Url : http://lists.samba.org/archive/samba-technical/attachments/20071226/0ee8c17c/attachment.bin


More information about the samba-technical mailing list