1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-06-27 16:36:03 +00:00

Async-related script cleanups

This commit is contained in:
sfan5 2021-08-28 12:15:12 +02:00 committed by GitHub
parent 0f8a6d78a7
commit 6a1424f2b1
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
15 changed files with 135 additions and 156 deletions

View file

@ -39,7 +39,6 @@ extern "C" {
#include "config.h"
#define SCRIPTAPI_LOCK_DEBUG
#define SCRIPTAPI_DEBUG
// MUST be an invalid mod name so that mods can't
// use that name to bypass security!
@ -108,7 +107,9 @@ public:
Client* getClient();
#endif
std::string getOrigin() { return m_last_run_mod; }
// IMPORTANT: these cannot be used for any security-related uses, they exist
// only to enrich error messages
const std::string &getOrigin() { return m_last_run_mod; }
void setOriginDirect(const char *origin);
void setOriginFromTableRaw(int index, const char *fxn);