diff options
author | Torok Edwin <edwintorok@gmail.com> | 2010-12-23 15:49:26 +0000 |
---|---|---|
committer | Torok Edwin <edwintorok@gmail.com> | 2010-12-23 15:49:26 +0000 |
commit | 5abf51bde02d6a3987e6c2f0cd76258ff340a870 (patch) | |
tree | eccb6d0dec7d324596246a2e823f33d5d28306cc /llvm/lib/Support/regexec.c | |
parent | dfa40f8f195c14b6080ec5214d3d1c7e01ee6195 (diff) | |
download | bcm5719-llvm-5abf51bde02d6a3987e6c2f0cd76258ff340a870.tar.gz bcm5719-llvm-5abf51bde02d6a3987e6c2f0cd76258ff340a870.zip |
Fix OCaml bindings crash, PR8847.
See http://caml.inria.fr/mantis/view.php?id=4166
If we call only external functions from a module, then its 'let _' bindings
don't get executed, which means that the exceptions don't get registered for use
in the C code.
This in turn causes llvm_raise to call raise_with_arg() with a NULL pointer and
cause a segmentation fault.
The workaround is to declare all 'external' functions as 'val' in these .mli
files.
Also added a separate testcase (the testcase must call only external functions
for the bug to occur).
llvm-svn: 122497
Diffstat (limited to 'llvm/lib/Support/regexec.c')
0 files changed, 0 insertions, 0 deletions