Commenting;

This commit is contained in:
bjorn 2020-01-15 17:56:09 -08:00
parent bd6d45cd30
commit 2a52796c6f
2 changed files with 4 additions and 3 deletions

View File

@ -86,9 +86,7 @@ static int l_lovrThreadGetChannel(lua_State* L) {
const char* name = luaL_checkstring(L, 1);
Channel* channel = lovrThreadGetChannel(name);
luax_pushtype(L, Channel, channel);
// Note: Channels are intentionally not released here
// Because the ownership of Channels is different from most objects, it is simpler to clean them
// all up in lovrThreadModuleDestroy.
// Note: Channels are intentionally not released here (see thread.h)
return 1;
}

View File

@ -4,6 +4,9 @@
#include <stdbool.h>
#include <stdint.h>
// Note: Channels retrieved with lovrThreadGetChannel don't need to be released. They're just all
// cleaned up when the thread module is destroyed.
#pragma once
#define MAX_THREAD_ARGUMENTS 4