Root cause:                                                                     
                                         
The goto out for cleanup can skip a variable initialization, so in some cases 
we                                         
crash on if(pathdirs) g_strfreev(pathdirs); because pathdirs is declared too    
                                         
late and, in that code flow, never initialized.                                 
                                         
                                                                                
                                         
We could thus also fix this by ensuring that pathdirs is properly initialized   
                                         
at the beginning of the function, but removing the reimplementation of          
                                         
g_find_program_in_path is the superior solution.                                
                                         

Attached is my proposed fix, however I don't think we should upload yet
since there appear to be some parallel work going on in
https://bugs.launchpad.net/ubuntu/+source/update-notifier/+bug/1883315

** Patch added: "update-notifier-1-3.192.41.debdiff"
   
https://bugs.launchpad.net/ubuntu/+source/update-notifier/+bug/1926298/+attachment/5492829/+files/update-notifier-1-3.192.41.debdiff

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1926298

Title:
  Segfault added in the recent changes

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/update-notifier/+bug/1926298/+subscriptions

-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to