Re: [systemd-devel] tests

2013-01-31 Thread Zbigniew Jędrzejewski-Szmek
On Thu, Jan 31, 2013 at 08:35:56AM +0100, Thomas H.P. Andersen wrote: > Hi Zbigniew, Hi, > _cleanup_free_ only cleans up when the variable goes out of scope > right? So just using it on "r" here would leak all but the last use of > it? Yes. > Using individual variables for each test case like r1

Re: [systemd-devel] tests

2013-01-30 Thread Thomas H.P. Andersen
Hi Zbigniew, _cleanup_free_ only cleans up when the variable goes out of scope right? So just using it on "r" here would leak all but the last use of it? Using individual variables for each test case like r1, r2, r3, etc could be a solution. Or using something like your recent "#define expect" wo

Re: [systemd-devel] tests

2013-01-30 Thread Zbigniew Jędrzejewski-Szmek
On Wed, Jan 30, 2013 at 10:18:46PM +0100, Daniel Buch wrote: > I did some improvements on strv-test.c and added additional test, more is > on its way. > > Patch files is attached. > > What do you think? Hi, more tests are usually good ;) Applied. In the future, try using _cleanup_free_, and plea

[systemd-devel] tests

2013-01-30 Thread Daniel Buch
I did some improvements on strv-test.c and added additional test, more is on its way. Patch files is attached. What do you think? 0001-test-strv.c-Split-tests-into-seperate-functions.patch Description: Binary data 0002-test-strv.c-test-strv_join-added.patch Description: Binary data __