You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
35 lines
1003 B
35 lines
1003 B
11 years ago
|
diff -ur lualdap-1.1.0.orig/src/lualdap.c lualdap-1.1.0/src/lualdap.c
|
||
|
--- lualdap-1.1.0.orig/src/lualdap.c 2007-12-15 01:11:22.000000000 +1000
|
||
|
+++ lualdap-1.1.0/src/lualdap.c 2014-06-05 15:34:22.657478715 +1000
|
||
|
@@ -25,6 +25,12 @@
|
||
|
#include "compat-5.1.h"
|
||
|
#endif
|
||
|
|
||
|
+#ifndef luaL_getn
|
||
|
+// Lua 5.1 converted this to a macro, 5.2 dropped it entirely...
|
||
|
+// This is the definition from 5.1
|
||
|
+#define luaL_getn(L,i) ((int)lua_objlen(L, i))
|
||
|
+#endif
|
||
|
+
|
||
|
#ifdef WINLDAPAPI
|
||
|
#define timeval l_timeval
|
||
|
typedef ULONG ldap_int_t;
|
||
|
@@ -872,7 +878,7 @@
|
||
|
** Create a metatable.
|
||
|
*/
|
||
|
static int lualdap_createmeta (lua_State *L) {
|
||
|
- const luaL_reg methods[] = {
|
||
|
+ const luaL_Reg methods[] = {
|
||
|
{"close", lualdap_close},
|
||
|
{"add", lualdap_add},
|
||
|
{"compare", lualdap_compare},
|
||
|
@@ -987,7 +993,7 @@
|
||
|
** Create ldap table and register the open method.
|
||
|
*/
|
||
|
int luaopen_lualdap (lua_State *L) {
|
||
|
- struct luaL_reg lualdap[] = {
|
||
|
+ struct luaL_Reg lualdap[] = {
|
||
|
{"open_simple", lualdap_open_simple},
|
||
|
{NULL, NULL},
|
||
|
};
|