Skip to content

Commit

Permalink
fix memleak in evmap_signal_clear; from Alexander Drozdov
Browse files Browse the repository at this point in the history
svn:r1049
  • Loading branch information
provos committed Jan 26, 2009
1 parent 765ff1b commit 0e77990
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion evmap.c
Original file line number Diff line number Diff line change
Expand Up @@ -228,7 +228,6 @@ evmap_signal_initmap(struct event_signal_map *ctx)
void
evmap_signal_clear(struct event_signal_map *ctx)
{
ctx->nentries = 0;
if (ctx->entries != NULL) {
int i;
for (i = 0; i < ctx->nentries; ++i) {
Expand All @@ -238,6 +237,7 @@ evmap_signal_clear(struct event_signal_map *ctx)
mm_free(ctx->entries);
ctx->entries = NULL;
}
ctx->nentries = 0;
}


Expand Down

0 comments on commit 0e77990

Please sign in to comment.