diff options
| author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2018-10-31 16:25:29 -0300 |
|---|---|---|
| committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2018-10-31 16:25:29 -0300 |
| commit | 2fc6b55dae7a120b4272ca0e9c356d1f96053bd9 (patch) | |
| tree | 073360734518f75a4f5621d87a4b47bc4642452a /loslib.c | |
| parent | 947a372f5860a76fcafb4a2845abc322e440d6fc (diff) | |
| download | lua-2fc6b55dae7a120b4272ca0e9c356d1f96053bd9.tar.gz lua-2fc6b55dae7a120b4272ca0e9c356d1f96053bd9.tar.bz2 lua-2fc6b55dae7a120b4272ca0e9c356d1f96053bd9.zip | |
Removed resource-related "emergency collections"
New to-be-closed variables is a better way to ensure the proper release
of resources.
Diffstat (limited to 'loslib.c')
| -rw-r--r-- | loslib.c | 2 |
1 files changed, 0 insertions, 2 deletions
| @@ -166,8 +166,6 @@ static int os_tmpname (lua_State *L) { | |||
| 166 | char buff[LUA_TMPNAMBUFSIZE]; | 166 | char buff[LUA_TMPNAMBUFSIZE]; |
| 167 | int err; | 167 | int err; |
| 168 | lua_tmpnam(buff, err); | 168 | lua_tmpnam(buff, err); |
| 169 | if (err && luaL_resourcetryagain(L)) /* resource failure? */ | ||
| 170 | lua_tmpnam(buff, err); /* try again */ | ||
| 171 | if (err) | 169 | if (err) |
| 172 | return luaL_error(L, "unable to generate a unique filename"); | 170 | return luaL_error(L, "unable to generate a unique filename"); |
| 173 | lua_pushstring(L, buff); | 171 | lua_pushstring(L, buff); |
