Don't crash if the fwupd error is null
ClosedPublic

Authored by leinir on Mar 6 2019, 10:49 AM.

Details

Summary

I got a difficult-to-reproduce crash, which pointed at the fact that this error can, at times, be null. Without the validity check this patch introduces, we then attempted to deref that null pointer, and crashed.

Diff Detail

Repository
R134 Discover Software Store
Lint
Lint Skipped
Unit
Unit Tests Skipped
leinir created this revision.Mar 6 2019, 10:49 AM
Restricted Application added a project: Plasma. · View Herald TranscriptMar 6 2019, 10:49 AM
Restricted Application added a subscriber: plasma-devel. · View Herald Transcript
leinir requested review of this revision.Mar 6 2019, 10:49 AM
ngraham accepted this revision.Mar 6 2019, 2:15 PM
This revision is now accepted and ready to land.Mar 6 2019, 2:15 PM
apol accepted this revision.Mar 6 2019, 3:01 PM

Cool, thanks! remember to land in 5.15.

leinir added a comment.Mar 6 2019, 3:01 PM
In D19561#425879, @apol wrote:

Cool, thanks! remember to land in 5.15.

Will do! :)

This revision was automatically updated to reflect the committed changes.