From d12254166a55d17932ea4143fbd50fb52539ff8b Mon Sep 17 00:00:00 2001 From: sin Date: Fri, 13 Mar 2015 23:09:15 +0000 Subject: Restore C++ support --- include/stdio.h | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'include/stdio.h') diff --git a/include/stdio.h b/include/stdio.h index f87bd59..5cf5b13 100644 --- a/include/stdio.h +++ b/include/stdio.h @@ -5,7 +5,10 @@ #if defined(_FORTIFY_SOURCE) && _FORTIFY_SOURCE > 0 && defined(__OPTIMIZE__) && __OPTIMIZE__ > 0 -#ifndef __cplusplus +#ifdef __cplusplus +extern "C" { +#endif + #undef fgets #undef fread #undef fwrite @@ -114,6 +117,8 @@ int sprintf(char *s, const char *fmt, ...) return r; } +#ifdef __cplusplus +} #endif #endif -- cgit v1.3