[systemd-devel] [PATCH 2/2] sysv-generator: remove NULL pointer dereference

Shawn Landden shawn at churchofgit.com
Sun Apr 26 11:21:33 PDT 2015


On Sun, Apr 26, 2015 at 11:15 AM, Thomas H.P. Andersen <phomes at gmail.com> wrote:
> Hi Shawn,
>
> I fixed this a few hours ago. I also updated the status in coverity.
> Is there something else I can do to avoid duplicated work?
I wasn't checking coverity, just reading the emails, so the duplicated
work in on my end.
>
> On Sun, Apr 26, 2015 at 7:58 PM, Shawn Landden <shawn at churchofgit.com> wrote:
>> (coverity)
>> ---
>>  src/sysv-generator/sysv-generator.c | 2 +-
>>  1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/src/sysv-generator/sysv-generator.c b/src/sysv-generator/sysv-generator.c
>> index 5ecd750..714ce8f 100644
>> --- a/src/sysv-generator/sysv-generator.c
>> +++ b/src/sysv-generator/sysv-generator.c
>> @@ -922,7 +922,7 @@ finish:
>>  int main(int argc, char *argv[]) {
>>          int r, q;
>>          _cleanup_lookup_paths_free_ LookupPaths lp = {};
>> -        _cleanup_(free_sysvstub_hashmapp) Hashmap *all_services;
>> +        _cleanup_(free_sysvstub_hashmapp) Hashmap *all_services = NULL;
>>          SysvStub *service;
>>          Iterator j;
>>
>> --
>> 2.2.1.209.g41e5f3a
>>
>> _______________________________________________
>> systemd-devel mailing list
>> systemd-devel at lists.freedesktop.org
>> http://lists.freedesktop.org/mailman/listinfo/systemd-devel
> _______________________________________________
> systemd-devel mailing list
> systemd-devel at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/systemd-devel



-- 
Shawn Landden


More information about the systemd-devel mailing list