[LLVMdev] Null pointer dereference

Yury Mikhaylov yury.mikhaylov at gmail.com
Wed May 9 15:40:05 PDT 2012


Hi all,

Writing my own LLVM client I've noticed a potential null pointer
dereference in EngineBuilder::selectTarget.

The class has an optional pointer to the ErrorStr, which can be initialzied
through setErrorStr() method. Although, it's strictly optional,
selectTarget doesn't verify its value before assignment.

Please find patch for branch release_31, revision 155051 attached.

- Yury
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20120509/c147de15/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: TargetSelect.patch
Type: application/octet-stream
Size: 488 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20120509/c147de15/attachment.obj>


More information about the llvm-dev mailing list