Re: [systemd-devel] hash context not closed.

2018-02-05 Thread Stef Bon
hi, maybe good to know that libgcrypt provides a function which offers "all in one": void gcry_md_hash_buffer (int algo, void *digest, const void *buffer, size_t length) digest can be an array created earlier using the function gcry_md_get_algo_dlen. Stef __

Re: [systemd-devel] hash context not closed.

2018-02-05 Thread Zbigniew Jędrzejewski-Szmek
On Mon, Feb 05, 2018 at 09:17:52AM +0100, Stef Bon wrote: > Same error here: > (gcry_md_open without gcry_md_close) > line 901 in src/resolve/resolved-dns-sec.c > while in the same file at 1227 it's done the good way. Indeed. PR submitted: https://github.com/systemd/systemd/pull/8100. Zbyszek ___

Re: [systemd-devel] hash context not closed.

2018-02-05 Thread Stef Bon
Same error here: (gcry_md_open without gcry_md_close) line 901 in src/resolve/resolved-dns-sec.c while in the same file at 1227 it's done the good way. Stef ___ systemd-devel mailing list systemd-devel@lists.freedesktop.org https://lists.freedesktop.org/

Re: [systemd-devel] hash context not closed.

2018-02-03 Thread vcaputo
On Sat, Feb 03, 2018 at 09:14:40PM +0100, Stef Bon wrote: > The testing of the new code requires me too much (meson is required.. > and I don't want to replace my existing systemd) and I do not expect > to add more patches is near future. > > I've got a patch: > > diff --git a/src/basic/gcrypt-ut

Re: [systemd-devel] hash context not closed.

2018-02-03 Thread Stef Bon
The testing of the new code requires me too much (meson is required.. and I don't want to replace my existing systemd) and I do not expect to add more patches is near future. I've got a patch: diff --git a/src/basic/gcrypt-util.c b/src/basic/gcrypt-util.c index 1bfb77672..c7c07e3b7 100644 --- a/s

Re: [systemd-devel] hash context not closed.

2018-02-03 Thread vcaputo
On Sat, Feb 03, 2018 at 08:38:38PM +0100, Stef Bon wrote: > 2018-02-03 20:27 GMT+01:00 : > > > > > Nice catch, that indeed looks like a leak. Would you like to prep a > > PR fixing it? > > > > PR? I do not know what you mean. A pull request? > I can write a patch. The systemd project uses gith

Re: [systemd-devel] hash context not closed.

2018-02-03 Thread Stef Bon
2018-02-03 20:27 GMT+01:00 : > > Nice catch, that indeed looks like a leak. Would you like to prep a > PR fixing it? > PR? I do not know what you mean. A pull request? I can write a patch. Stef ___ systemd-devel mailing list systemd-devel@lists.freed

Re: [systemd-devel] hash context not closed.

2018-02-03 Thread vcaputo
On Sat, Feb 03, 2018 at 07:26:24PM +0100, Stef Bon wrote: > Hi, > > when I look at the function string_hashsum it looks like the context > is not closed when done. > > After a succesfull gcry_md_open the hash context md should be closed > when leaving this function. That does not happen. > Nice

Re: [systemd-devel] hash context not closed.

2018-02-03 Thread Stef Bon
2018-02-03 19:26 GMT+01:00 Stef Bon : > Hi, Oh and this in in file src/basic/gcrypt-util.c. > > Stef ___ systemd-devel mailing list systemd-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/systemd-devel

[systemd-devel] hash context not closed.

2018-02-03 Thread Stef Bon
Hi, when I look at the function string_hashsum it looks like the context is not closed when done. After a succesfull gcry_md_open the hash context md should be closed when leaving this function. That does not happen. Stef ___ systemd-devel mailing list