Browse Source

better to flush all files before starting new process with popen

Roberto Ierusalimschy 18 years ago
parent
commit
9b47cee8b2
1 changed files with 2 additions and 2 deletions
  1. 2 2
      luaconf.h

+ 2 - 2
luaconf.h

@@ -1,5 +1,5 @@
 /*
-** $Id: luaconf.h,v 1.89 2007/06/21 13:48:04 roberto Exp roberto $
+** $Id: luaconf.h,v 1.90 2007/06/22 16:59:11 roberto Exp roberto $
 ** Configuration file for Lua
 ** See Copyright Notice in lua.h
 */
@@ -656,7 +656,7 @@ union luai_Cast { double l_d; long l_l; };
 */
 #if defined(LUA_USE_POPEN)
 
-#define lua_popen(L,c,m)	((void)L, popen(c,m))
+#define lua_popen(L,c,m)	((void)L, fflush(NULL), popen(c,m))
 #define lua_pclose(L,file)	((void)L, (pclose(file) != -1))
 
 #elif defined(LUA_WIN)