| 244 | |
| 245 | |
| 246 | static int io_popen (lua_State *L) { |
| 247 | const char *filename = luaL_checkstring(L, 1); |
| 248 | const char *mode = luaL_optstring(L, 2, "r"); |
| 249 | LStream *p = newprefile(L); |
| 250 | p->f = lua_popen(L, filename, mode); |
| 251 | p->closef = &io_pclose; |
| 252 | return (p->f == NULL) ? luaL_fileresult(L, 0, filename) : 1; |
| 253 | } |
| 254 | |
| 255 | |
| 256 | static int io_tmpfile (lua_State *L) { |
nothing calls this directly
no test coverage detected