* strings.c (print_strings): Plug memory leak.
* ar.c (move_members): Plug memory leak.
+ (delete_members): Plug memory leak.
2011-03-25 Pierre Muller <muller@ics.u-strasbg.fr>
bfd_boolean found;
bfd_boolean something_changed = FALSE;
int match_count;
+ const char * tmp = NULL;
for (; *files_to_delete != NULL; ++files_to_delete)
{
current_ptr_ptr = &(arch->archive_next);
while (*current_ptr_ptr)
{
- if (FILENAME_CMP (normalize (*files_to_delete, arch),
- (*current_ptr_ptr)->filename) == 0)
+ if (tmp != NULL)
+ free ((char *) tmp);
+ tmp = normalize (*files_to_delete, arch);
+ if (FILENAME_CMP (tmp, (*current_ptr_ptr)->filename) == 0)
{
++match_count;
if (counted_name_mode
write_archive (arch);
else
output_filename = NULL;
+
+ if (tmp != NULL)
+ free ((char *) tmp);
}