mirror of
https://github.com/MidnightCommander/mc
synced 2024-12-23 04:46:55 +03:00
* screen.c (panel_destroy): Rewind history to the beginning
before freeing it. * widget.c (input_destroy): Likewise. * util.c (list_append_unique): Free data when removing duplicate list entries.
This commit is contained in:
parent
4a398f0ee7
commit
99e1805194
@ -1,6 +1,14 @@
|
||||
2003-06-05 Pavel Roskin <proski@gnu.org>
|
||||
|
||||
* screen.c (panel_destroy): Rewind history to the beginning
|
||||
before freeing it.
|
||||
* widget.c (input_destroy): Likewise.
|
||||
* util.c (list_append_unique): Free data when removing duplicate
|
||||
list entries.
|
||||
|
||||
2003-05-29 Andrew V. Samoilov <sav@bcs.zp.ua>
|
||||
|
||||
key.c (init_key): Fix crash if TERM is unset.
|
||||
* key.c (init_key): Fix crash if TERM is unset.
|
||||
|
||||
2003-05-29 Koblinger Egmont <egmont@uhulinux.hu>
|
||||
|
||||
|
@ -896,9 +896,10 @@ panel_destroy (WPanel *p)
|
||||
panel_clean_dir (p);
|
||||
|
||||
/* save and clean history */
|
||||
if (p->dir_history){
|
||||
if (p->dir_history) {
|
||||
history_put (p->hist_name, p->dir_history);
|
||||
|
||||
p->dir_history = g_list_first (p->dir_history);
|
||||
g_list_foreach (p->dir_history, (GFunc) g_free, NULL);
|
||||
g_list_free (p->dir_history);
|
||||
}
|
||||
@ -910,7 +911,7 @@ panel_destroy (WPanel *p)
|
||||
|
||||
g_free (p->user_format);
|
||||
for (i = 0; i < LIST_TYPES; i++)
|
||||
g_free (p->user_status_format [i]);
|
||||
g_free (p->user_status_format[i]);
|
||||
g_free (p->dir.list);
|
||||
g_free (p->panel_name);
|
||||
g_free (name);
|
||||
|
@ -1190,6 +1190,7 @@ list_append_unique (GList *list, char *text)
|
||||
while (link) {
|
||||
newlink = g_list_previous (link);
|
||||
if (!strcmp ((char *) link->data, text)) {
|
||||
g_free (link->data);
|
||||
g_list_remove_link (list, link);
|
||||
g_list_free_1 (link);
|
||||
}
|
||||
|
@ -1009,6 +1009,7 @@ input_destroy (WInput *in)
|
||||
if (!in->is_password) /* don't save passwords ;-) */
|
||||
history_put (in->history_name, in->history);
|
||||
|
||||
in->history = g_list_first (in->history);
|
||||
g_list_foreach (in->history, (GFunc) g_free, NULL);
|
||||
g_list_free (in->history);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user