[C API] Prevent nullptr dereferences in C API for counting attributes.
authorAmaury Sechet <deadalnix@gmail.com>
Tue, 15 Nov 2016 22:19:59 +0000 (22:19 +0000)
committerAmaury Sechet <deadalnix@gmail.com>
Tue, 15 Nov 2016 22:19:59 +0000 (22:19 +0000)
commit003216b319d7f12f7245b183741500a478bfd641
tree09245b66bbbe7b203b08e1de619ca50bf734f9b5
parentf5f37ee546bd05427e37b5e9ab2cbcb2ac72f5cc
[C API] Prevent nullptr dereferences in C API for counting attributes.

See https://reviews.llvm.org/D26392

Patch by @maleadt

llvm-svn: 287044
llvm/test/Bindings/llvm-c/callsite_attributes.ll [new file with mode: 0644]
llvm/test/Bindings/llvm-c/function_attributes.ll [new file with mode: 0644]
llvm/tools/llvm-c-test/CMakeLists.txt
llvm/tools/llvm-c-test/attributes.c [new file with mode: 0644]
llvm/tools/llvm-c-test/llvm-c-test.h
llvm/tools/llvm-c-test/main.c