aboutsummaryrefslogtreecommitdiff
path: root/gdb/event-loop.c
diff options
context:
space:
mode:
authorSimon Marchi <simon.marchi@ericsson.com>2017-06-02 23:24:21 +0200
committerSimon Marchi <simon.marchi@ericsson.com>2017-06-02 23:24:21 +0200
commit0e05cf3a61e1996829359e1c32eedb6820930331 (patch)
tree293c8b0eeaecae5461e15839a16262b69d366064 /gdb/event-loop.c
parentc1fc2657206188767cb66813d07b9ecbb5e9ec51 (diff)
downloadgdb-0e05cf3a61e1996829359e1c32eedb6820930331.zip
gdb-0e05cf3a61e1996829359e1c32eedb6820930331.tar.gz
gdb-0e05cf3a61e1996829359e1c32eedb6820930331.tar.bz2
Use delete instead of xfree for gdb_timer
gdb_timer objects are new'ed in create_timer, but xfree'd in poll_timers. Use delete instead. gdb/ChangeLog: * event-loop.c (poll_timers): Unallocate timer using delete instead of xfree.
Diffstat (limited to 'gdb/event-loop.c')
-rw-r--r--gdb/event-loop.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/gdb/event-loop.c b/gdb/event-loop.c
index 4b3ddb8..7304ca7 100644
--- a/gdb/event-loop.c
+++ b/gdb/event-loop.c
@@ -1270,7 +1270,7 @@ poll_timers (void)
/* Delete the timer before calling the callback, not after, in
case the callback itself decides to try deleting the timer
too. */
- xfree (timer_ptr);
+ delete timer_ptr;
/* Call the procedure associated with that timer. */
(proc) (client_data);