This is an archive of the discontinued LLVM Phabricator instance.

Fix crash in handling back-end warnings
ClosedPublic

Authored by gberry on May 1 2015, 3:21 PM.

Details

Summary

Fix BackendConsumer::EmitOptimizationMessage() to check if the
DiagnosticInfoOptimizationBase object has a valid location before
calling getLocation() to avoid dereferencing a null pointer inside
getLocation() when no debug info is present.

Diff Detail

Event Timeline

gberry updated this revision to Diff 24837.May 1 2015, 3:21 PM
gberry retitled this revision from to Fix crash in handling back-end warnings.
gberry updated this object.
gberry edited the test plan for this revision. (Show Details)
gberry added a subscriber: Unknown Object (MLST).
mcrosier edited reviewers, added: dexonsmith; removed: mcrosier.May 4 2015, 2:42 PM
mcrosier added a subscriber: mcrosier.
gberry updated this revision to Diff 25333.May 8 2015, 8:10 AM

Incorporate feedback from Diego.

gberry added a comment.May 8 2015, 8:12 AM

Hi Diego,

Thanks for looking at this. I've uploaded a new version that hopefully incorporates your feedback.

http://reviews.llvm.org/D9449

Geoff Berry
Employee of Qualcomm Innovation Center, Inc.
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, a Linux Foundation Collaborative Project

dnovillo edited edge metadata.May 8 2015, 1:53 PM

Ignore me. I'm seeing things.

mcrosier accepted this revision.May 11 2015, 11:07 AM
mcrosier added a reviewer: mcrosier.
This revision is now accepted and ready to land.May 11 2015, 11:07 AM
mcrosier closed this revision.May 11 2015, 11:07 AM

Committed by Diego in r236898.