git.samba.org
/
ira
/
wip.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
ceac260
)
tevent: don't crash if te->event_ctx is NULL
author
Stefan Metzmacher
<metze@samba.org>
Mon, 5 Jan 2009 18:22:22 +0000
(19:22 +0100)
committer
Stefan Metzmacher
<metze@samba.org>
Mon, 5 Jan 2009 21:44:54 +0000
(22:44 +0100)
metze
lib/tevent/tevent_timed.c
patch
|
blob
|
history
diff --git
a/lib/tevent/tevent_timed.c
b/lib/tevent/tevent_timed.c
index dadd360416419e745338c8564ca02244b788b84d..78c8a24511a8002c8953136147652ad082d3318b 100644
(file)
--- a/
lib/tevent/tevent_timed.c
+++ b/
lib/tevent/tevent_timed.c
@@
-108,9
+108,9
@@
bool ev_timeval_is_zero(const struct timeval *tv)
*/
static int tevent_common_timed_destructor(struct tevent_timer *te)
{
- struct tevent_context *ev = talloc_get_type(te->event_ctx,
-
struct tevent_context
);
- DLIST_REMOVE(ev->timer_events, te);
+ if (te->event_ctx) {
+
DLIST_REMOVE(te->event_ctx->timer_events, te
);
+ }
return 0;
}