static void lua_cb_free(void *data) {
clua_callback_data_t *cb = data;
free(cb->lua_function_name);
+ pthread_mutex_destroy(&cb->lock);
free(cb);
}
else
ERROR("Lua plugin: Executing script \"%s\" failed:\n%s",
script_path, errmsg);
-
- lua_script_free(script);
- return -1;
}
/* Append this script to the global list of scripts. */
scripts = script;
}
+ if (status != 0)
+ return -1;
+
return 0;
} /* }}} int lua_script_load */