mirror of
https://github.com/tuxbox-neutrino/neutrino.git
synced 2025-08-29 08:21:12 +02:00
CLuaInstance: Fix and unified script function calls
- No api changes, code only
This commit is contained in:
@@ -173,6 +173,8 @@ Example:
|
||||
#define CURL_MSG_ERROR "[curl:download \33[1;31mERROR!\33[0m]"
|
||||
|
||||
lua_assert(lua_istable(L,1));
|
||||
CLuaCurl *D = CurlCheckData(L, 1);
|
||||
if (!D) return 0;
|
||||
|
||||
char errMsg[1024];
|
||||
CURL *curl_handle = curl_easy_init();
|
||||
@@ -359,6 +361,7 @@ Example:
|
||||
int CLuaInstCurl::CurlDelete(lua_State *L)
|
||||
{
|
||||
CLuaCurl *D = CurlCheckData(L, 1);
|
||||
if (!D) return 0;
|
||||
delete D;
|
||||
return 0;
|
||||
}
|
||||
|
Reference in New Issue
Block a user