Make up the right dependencies now that ldb depends on libevents
[kamenim/samba.git] / source4 / dsdb / samdb / samdb.c
index 9154f5382ba6eebd7ef93598247be6a4c9e68414..4557b6c9ccb49d989307cfb5080078ad5b97a5ed 100644 (file)
@@ -25,6 +25,7 @@
 #include "librpc/gen_ndr/ndr_netlogon.h"
 #include "librpc/gen_ndr/ndr_misc.h"
 #include "librpc/gen_ndr/ndr_security.h"
+#include "lib/events/events.h"
 #include "lib/ldb/include/ldb.h"
 #include "lib/ldb/include/ldb_errors.h"
 #include "libcli/security/security.h"
@@ -114,7 +115,7 @@ int samdb_copy_template(struct ldb_context *ldb,
                        return LDB_ERR_OPERATIONS_ERROR;
                }
                
-               event_ctx = (struct event_context *)ldb_get_opaque(ldb, "EventContext");
+               event_ctx = ldb_get_event_context(ldb);
                lp_ctx = (struct loadparm_context *)ldb_get_opaque(ldb, "loadparm");
 
                /* FIXME: need to remove this wehn we finally pass the event