summaryrefslogtreecommitdiff
path: root/apps/plugins/lua/lundump.h
diff options
context:
space:
mode:
Diffstat (limited to 'apps/plugins/lua/lundump.h')
-rw-r--r--apps/plugins/lua/lundump.h22
1 files changed, 7 insertions, 15 deletions
diff --git a/apps/plugins/lua/lundump.h b/apps/plugins/lua/lundump.h
index f791a4f173..5255db259d 100644
--- a/apps/plugins/lua/lundump.h
+++ b/apps/plugins/lua/lundump.h
@@ -1,5 +1,5 @@
1/* 1/*
2** $Id$ 2** $Id: lundump.h,v 1.39.1.1 2013/04/12 18:48:47 roberto Exp $
3** load precompiled Lua chunks 3** load precompiled Lua chunks
4** See Copyright Notice in lua.h 4** See Copyright Notice in lua.h
5*/ 5*/
@@ -11,26 +11,18 @@
11#include "lzio.h" 11#include "lzio.h"
12 12
13/* load one chunk; from lundump.c */ 13/* load one chunk; from lundump.c */
14LUAI_FUNC Proto* luaU_undump (lua_State* L, ZIO* Z, Mbuffer* buff, const char* name); 14LUAI_FUNC Closure* luaU_undump (lua_State* L, ZIO* Z, Mbuffer* buff, const char* name);
15 15
16/* make header; from lundump.c */ 16/* make header; from lundump.c */
17LUAI_FUNC void luaU_header (char* h); 17LUAI_FUNC void luaU_header (lu_byte* h);
18 18
19/* dump one chunk; from ldump.c */ 19/* dump one chunk; from ldump.c */
20LUAI_FUNC int luaU_dump (lua_State* L, const Proto* f, lua_Writer w, void* data, int strip); 20LUAI_FUNC int luaU_dump (lua_State* L, const Proto* f, lua_Writer w, void* data, int strip);
21 21
22#ifdef luac_c 22/* data to catch conversion errors */
23/* print one chunk; from print.c */ 23#define LUAC_TAIL "\x19\x93\r\n\x1a\n"
24LUAI_FUNC void luaU_print (const Proto* f, int full);
25#endif
26
27/* for header of binary files -- this is Lua 5.1 */
28#define LUAC_VERSION 0x51
29
30/* for header of binary files -- this is the official format */
31#define LUAC_FORMAT 0
32 24
33/* size of header of binary files */ 25/* size in bytes of header of binary files */
34#define LUAC_HEADERSIZE 12 26#define LUAC_HEADERSIZE (sizeof(LUA_SIGNATURE)-sizeof(char)+2+6+sizeof(LUAC_TAIL)-sizeof(char))
35 27
36#endif 28#endif