mirror of
https://github.com/vim/vim.git
synced 2025-07-25 10:54:51 -04:00
patch 7.4.2130
Problem: Pending timers cause false memory leak reports. Solution: Free all timers on exit.
This commit is contained in:
parent
3ab14355ed
commit
623e263ffb
@ -1279,6 +1279,21 @@ set_ref_in_timer(int copyID)
|
|||||||
}
|
}
|
||||||
return abort;
|
return abort;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# if defined(EXITFREE) || defined(PROTO)
|
||||||
|
void
|
||||||
|
timer_free_all()
|
||||||
|
{
|
||||||
|
timer_T *timer;
|
||||||
|
|
||||||
|
while (first_timer != NULL)
|
||||||
|
{
|
||||||
|
timer = first_timer;
|
||||||
|
remove_timer(timer);
|
||||||
|
free_timer(timer);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
# endif
|
||||||
# endif
|
# endif
|
||||||
|
|
||||||
#if defined(FEAT_SYN_HL) && defined(FEAT_RELTIME) && defined(FEAT_FLOAT)
|
#if defined(FEAT_SYN_HL) && defined(FEAT_RELTIME) && defined(FEAT_FLOAT)
|
||||||
|
@ -1224,6 +1224,9 @@ free_all_mem(void)
|
|||||||
channel_free_all();
|
channel_free_all();
|
||||||
job_free_all();
|
job_free_all();
|
||||||
# endif
|
# endif
|
||||||
|
#ifdef FEAT_TIMERS
|
||||||
|
timer_free_all();
|
||||||
|
#endif
|
||||||
|
|
||||||
free_termoptions();
|
free_termoptions();
|
||||||
|
|
||||||
|
@ -18,11 +18,12 @@ float_T profile_float(proftime_T *tm);
|
|||||||
void profile_setlimit(long msec, proftime_T *tm);
|
void profile_setlimit(long msec, proftime_T *tm);
|
||||||
int profile_passed_limit(proftime_T *tm);
|
int profile_passed_limit(proftime_T *tm);
|
||||||
void profile_zero(proftime_T *tm);
|
void profile_zero(proftime_T *tm);
|
||||||
timer_T *create_timer(long msec, int repeats);
|
timer_T *create_timer(long msec, int repeat);
|
||||||
long check_due_timer(void);
|
long check_due_timer(void);
|
||||||
timer_T *find_timer(int id);
|
timer_T *find_timer(int id);
|
||||||
void stop_timer(timer_T *timer);
|
void stop_timer(timer_T *timer);
|
||||||
int set_ref_in_timer(int copyID);
|
int set_ref_in_timer(int copyID);
|
||||||
|
void timer_free_all(void);
|
||||||
void profile_divide(proftime_T *tm, int count, proftime_T *tm2);
|
void profile_divide(proftime_T *tm, int count, proftime_T *tm2);
|
||||||
void profile_add(proftime_T *tm, proftime_T *tm2);
|
void profile_add(proftime_T *tm, proftime_T *tm2);
|
||||||
void profile_self(proftime_T *self, proftime_T *total, proftime_T *children);
|
void profile_self(proftime_T *self, proftime_T *total, proftime_T *children);
|
||||||
|
@ -763,6 +763,8 @@ static char *(features[]) =
|
|||||||
|
|
||||||
static int included_patches[] =
|
static int included_patches[] =
|
||||||
{ /* Add new patch number below this line */
|
{ /* Add new patch number below this line */
|
||||||
|
/**/
|
||||||
|
2130,
|
||||||
/**/
|
/**/
|
||||||
2129,
|
2129,
|
||||||
/**/
|
/**/
|
||||||
|
Loading…
x
Reference in New Issue
Block a user