Skip to content
Permalink
Browse files

caja-file: Fix use of memory after it is freed

to avoid warning with Clang Analyzer
  • Loading branch information...
sc0w committed Feb 25, 2019
1 parent 0bd2d81 commit 6e6c9c6b456718ba76ecbd2d956f718374ffd3cd
Showing with 13 additions and 7 deletions.
  1. +13 −7 libcaja-private/caja-file.c
@@ -8299,10 +8299,10 @@ file_list_file_ready_callback (CajaFile *file,

void
caja_file_list_call_when_ready (GList *file_list,
CajaFileAttributes attributes,
CajaFileListHandle **handle,
CajaFileListCallback callback,
gpointer callback_data)
CajaFileAttributes attributes,
CajaFileListHandle **handle,
CajaFileListCallback callback,
gpointer callback_data)
{
GList *l;
FileListReadyData *data;
@@ -8323,11 +8323,17 @@ caja_file_list_call_when_ready (GList *file_list,
file = CAJA_FILE (l->data);
/* Need to do this here, as the list can be modified by this call */
l = l->next;

caja_file_call_when_ready (file,
attributes,
file_list_file_ready_callback,
data);
attributes,
file_list_file_ready_callback,
data);

data = file_list_ready_data_new
(file_list, callback, callback_data);
}

file_list_ready_data_free (data);
}

void

0 comments on commit 6e6c9c6

Please sign in to comment.
You can’t perform that action at this time.