[OPENMP] Fix for PR31643: Clang crashes when compiling code on Windows
authorAlexey Bataev <a.bataev@hotmail.com>
Fri, 20 Jan 2017 08:57:28 +0000 (08:57 +0000)
committerAlexey Bataev <a.bataev@hotmail.com>
Fri, 20 Jan 2017 08:57:28 +0000 (08:57 +0000)
commit880d8605e33704d9c46aef60e6139ce4b3200275
tree8ab3840a61b8b987e0520406be196c802096112a
parente9b18e3d34f3dbea1649c6633b11d99eda798ec2
[OPENMP] Fix for PR31643: Clang crashes when compiling code on Windows
with SEH and openmp

In some cituations (during codegen for Windows SEH constructs)
CodeGenFunction instance may have CurFn equal to nullptr. OpenMP related
code does not expect such situation during cleanup.

llvm-svn: 292590
clang/lib/CodeGen/CodeGenFunction.cpp
clang/test/OpenMP/openmp_seh.c [new file with mode: 0644]