summaryrefslogtreecommitdiffstats
path: root/ctdb/server/ctdb_freeze.c
diff options
context:
space:
mode:
authorRusty Russell <rusty@rustcorp.com.au>2010-08-18 09:16:31 +0930
committerRusty Russell <rusty@rustcorp.com.au>2010-08-18 09:16:31 +0930
commitf93440c4b7febb67e23580a6217ada832fa6318a (patch)
tree2c86215a1673329bdb3486e6bcd9bb74f2e1088f /ctdb/server/ctdb_freeze.c
parent532e4a7077524c699b88d0b7c02984d5920e1c58 (diff)
downloadsamba-f93440c4b7febb67e23580a6217ada832fa6318a.tar.gz
samba-f93440c4b7febb67e23580a6217ada832fa6318a.tar.xz
samba-f93440c4b7febb67e23580a6217ada832fa6318a.zip
event: Update events to latest Samba version 0.9.8
In Samba this is now called "tevent", and while we use the backwards compatibility wrappers they don't offer EVENT_FD_AUTOCLOSE: that is now a separate tevent_fd_set_auto_close() function. This is based on Samba version 7f29f817fa939ef1bbb740584f09e76e2ecd5b06. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> (This used to be ctdb commit 85e5e760cc91eb3157d3a88996ce474491646726)
Diffstat (limited to 'ctdb/server/ctdb_freeze.c')
-rw-r--r--ctdb/server/ctdb_freeze.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/ctdb/server/ctdb_freeze.c b/ctdb/server/ctdb_freeze.c
index e641ef3ae68..924a7131e85 100644
--- a/ctdb/server/ctdb_freeze.c
+++ b/ctdb/server/ctdb_freeze.c
@@ -17,7 +17,7 @@
along with this program; if not, see <http://www.gnu.org/licenses/>.
*/
#include "includes.h"
-#include "lib/events/events.h"
+#include "lib/tevent/tevent.h"
#include "lib/tdb/include/tdb.h"
#include "system/network.h"
#include "system/filesys.h"
@@ -231,7 +231,7 @@ static struct ctdb_freeze_handle *ctdb_freeze_lock(struct ctdb_context *ctdb, ui
h->fd = fd[0];
- fde = event_add_fd(ctdb->ev, h, h->fd, EVENT_FD_READ|EVENT_FD_AUTOCLOSE,
+ fde = event_add_fd(ctdb->ev, h, h->fd, EVENT_FD_READ,
ctdb_freeze_lock_handler, h);
if (fde == NULL) {
DEBUG(DEBUG_ERR,("Failed to setup fd event for ctdb_freeze_lock\n"));
@@ -239,6 +239,7 @@ static struct ctdb_freeze_handle *ctdb_freeze_lock(struct ctdb_context *ctdb, ui
talloc_free(h);
return NULL;
}
+ tevent_fd_set_auto_close(fde);
return h;
}