Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion uloop-epoll.c
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,10 @@ static int timer_register(struct uloop_interval *tm, unsigned int msecs)

static int timer_remove(struct uloop_interval *tm)
{
int ret = __uloop_fd_delete(&tm->priv.ufd);
if (!tm->priv.ufd.registered)
return 0;

int ret = uloop_fd_delete(&tm->priv.ufd);

if (ret == 0) {
close(tm->priv.ufd.fd);
Expand Down