Skip to content

Commit

Permalink
free memory
Browse files Browse the repository at this point in the history
  • Loading branch information
burilovmv committed Jul 8, 2017
1 parent c5d527f commit b6b3fe2
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/ctx.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -111,6 +111,11 @@ bool zmq::ctx_t::check_tag ()

void zmq::ctx_t::set_error_handler(zmq_error_fn ffn, void* data)
{
if(error_data)
{
free(error_data);
}

error_fn = ffn;
error_data = data;
}
Expand Down

0 comments on commit b6b3fe2

Please sign in to comment.