-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://reviewboard-openlmi.rhcloud.com/r/967/#review1366
-----------------------------------------------------------
Ship it!
Ship It!
- Michal Minar
On Oct. 8, 2013, 3:58 p.m., Tomáš Bžatek wrote:
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://reviewboard-openlmi.rhcloud.com/r/967/
-----------------------------------------------------------
(Updated Oct. 8, 2013, 3:58 p.m.)
Review request for OpenLMI Developers.
Repository: openlmi-providers
Description
-------
parse_config: Don't reuse already initialized GError struct
Setting an error on top of an existing error is considered a programmer's
bug, possibly leaking memory. So do proper cleanup before reusing that
variable.
Also, errors set while retrieving keys and values are not checked anywhere
so let's just don't set them. Returned NULL values in case of error should
be enough to skip the particular value.
--
This happens when not having the openlmi.conf file installed, failing in two file reads
in a row.
Diffs
-----
src/openlmi.c 25cf57c86b4e05983f376dff69d6d52a25182daa
Diff:
http://reviewboard-openlmi.rhcloud.com/r/967/diff/
Testing
-------
Thanks,
Tomáš Bžatek