From 13cb900551b17474b6027dcb5dbf4b904a772bb9 Mon Sep 17 00:00:00 2001 From: Dwayne Boone Date: Fri, 7 Mar 2008 11:37:05 -0330 Subject: Updated mcpp patch --- cpp/src/Slice/Preprocessor.cpp | 23 ----------------------- 1 file changed, 23 deletions(-) (limited to 'cpp/src/Slice/Preprocessor.cpp') diff --git a/cpp/src/Slice/Preprocessor.cpp b/cpp/src/Slice/Preprocessor.cpp index 2a26aa026af..b5efe23096e 100755 --- a/cpp/src/Slice/Preprocessor.cpp +++ b/cpp/src/Slice/Preprocessor.cpp @@ -152,17 +152,6 @@ Slice::Preprocessor::preprocess(bool keepComments) argv[i + 1] = args[i].c_str(); } - // - // Mcpp redirects stdin which causes problems for Python - // and Ruby applications which use loadSlice. Therefore - // we need to save handle to stdin so we can restore it - // after mcpp has finished its processing. - // -#ifndef _WIN32 - int stdin_save; - stdin_save = dup(0); -#endif - // // Call mcpp using memory buffer. // @@ -170,18 +159,6 @@ Slice::Preprocessor::preprocess(bool keepComments) mcpp_lib_main(static_cast(args.size()) + 1, const_cast(argv)); delete[] argv; - // - // Restore stdin. - // -#ifdef _WIN32 - freopen("CON", "rt", stdin); -#else - fflush(stdin); - ::close(0); - dup2(stdin_save, 0); - ::close(stdin_save); -#endif - // // Write output to temporary file. Print errors to stderr. // -- cgit v1.2.3