[PATCH 22/23] gpo: Add gpo tests

David Mulder dmulder at suse.com
Fri Apr 28 12:36:38 UTC 2017

On 04/27/2017 01:49 PM, Andrew Bartlett wrote:
> In Subject: [PATCH 02/22] gpo: Add python libgpo bindings:
> The py_gpo_get_unix_path() routine and others like it appears to leak
> the result of talloc_new(NULL).
> I also am totally unclear how py_ads_parse_gp_ext() is used, tested or
> even works - it appears to blindly cast a C object to a python object
> and has a memory leak.
> The same I could say for py_ads_get_gpo_link, which tries to build a
> tuple with a raw C object, and leaks memory.  It also has really
> strange indentation and // comments, and is commented out in the end.
> I know this isn't your code!  However it means we have to go over
> everything with a fine toothed comb.  A patch to trim it down to the
> bare minimum required would go a long way.
> Comprehensive tests for the bindings and for the now modular script
> directly would go a long way to improving my confidence with this patch
> set.
Thanks for the feedback. Clearly I didn't take enough time to look over 
the libgpo bindings. Looks like most of that code is really WIP.
I'll start by trimming down anything that isn't used in there, then work 
on writing some tests for it.

David Mulder
SUSE Labs Software Engineer - Samba
dmulder at suse.com
SUSE Linux GmbH, GF: Felix Imend├Ârffer, Jane Smithard, Graham Norton, HRB 21284 (AG N├╝rnberg)

More information about the samba-technical mailing list