MCPcopy Create free account
hub / github.com/Snapchat/KeyDB / mp_buf_free

Function mp_buf_free

deps/lua/src/lua_cmsgpack.c:130–133  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

128}
129
130void mp_buf_free(lua_State *L, mp_buf *buf) {
131 mp_realloc(L, buf->b, buf->len + buf->free, 0); /* realloc to 0 = free */
132 mp_realloc(L, buf, sizeof(*buf), 0);
133}
134
135/* ---------------------------- String cursor ----------------------------------
136 * This simple data structure is used for parsing. Basically you create a cursor

Callers 1

mp_packFunction · 0.85

Calls 1

mp_reallocFunction · 0.85

Tested by

no test coverage detected