Просмотр исходного кода
dpkg-query: fix segfault when -f parameter is empty
Giving an empty parameter seems pretty useless, but it can also be
the result of user errors like using “-f "${Package}"” instead
of “-f '${Package}'” and the segfault does not really help to
understand one's fault.
This commit fixes pkg_format_parse() to define the error message
when the function had nothing to parse. It already returned
the appropriate NULL value but the fact that the error message
was uninitialized resulted in the segfault.