Signed-off-by: Zebediah Figura zfigura@codeweavers.com --- dlls/ucrtbase/Makefile.in | 1 + dlls/ucrtbase/setjmp.c | 32 ++++++++++++++++++++++++++++++++ 2 files changed, 33 insertions(+) create mode 100644 dlls/ucrtbase/setjmp.c
diff --git a/dlls/ucrtbase/Makefile.in b/dlls/ucrtbase/Makefile.in index bf7f62ada8a..e7d0759072c 100644 --- a/dlls/ucrtbase/Makefile.in +++ b/dlls/ucrtbase/Makefile.in @@ -36,6 +36,7 @@ C_SRCS = \ printf.c \ process.c \ scanf.c \ + setjmp.c \ sincos.c \ string.c \ thread.c \ diff --git a/dlls/ucrtbase/setjmp.c b/dlls/ucrtbase/setjmp.c new file mode 100644 index 00000000000..fb76b91c5a8 --- /dev/null +++ b/dlls/ucrtbase/setjmp.c @@ -0,0 +1,32 @@ +/* + * Copyright 2021 Zebediah Figura + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +/* these functions are part of the import lib for compatibility with the Mingw runtime */ +#if 0 +#pragma makedep implib +#endif + +#include <setjmp.h> + +#undef _setjmp +extern int DECLSPEC_NOTHROW DECLSPEC_RETURNS_TWICE __cdecl __intrinsic_setjmp(jmp_buf); + +int DECLSPEC_NOTHROW DECLSPEC_RETURNS_TWICE __cdecl _setjmp(jmp_buf buf) +{ + return __intrinsic_setjmp(buf); +}