From 95b2e0574014626ad9b4cd3bb15d3b8cf703f453 Mon Sep 17 00:00:00 2001 From: nickc Date: Thu, 9 Sep 2004 11:52:40 +0000 Subject: [PATCH] PR 363 * ar.c (replace_members): Do not use get_file_size as ar_emul_append correctly handles missing files. --- binutils/ChangeLog | 6 ++++++ binutils/ar.c | 5 ++--- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/binutils/ChangeLog b/binutils/ChangeLog index d80314c4b1..93f96d71d8 100644 --- a/binutils/ChangeLog +++ b/binutils/ChangeLog @@ -1,3 +1,9 @@ +2004-09-09 Nick Clifton + + PR 363 + * ar.c (replace_members): Do not use get_file_size as + ar_emul_append correctly handles missing files. + 2004-09-07 H.J. Lu * configure: Regenerated with autconfig 2.13. diff --git a/binutils/ar.c b/binutils/ar.c index ec0657d638..ab54ace33e 100644 --- a/binutils/ar.c +++ b/binutils/ar.c @@ -1268,7 +1268,7 @@ static void replace_members (bfd *arch, char **files_to_move, bfd_boolean quick) { bfd_boolean changed = FALSE; - bfd **after_bfd; /* New entries go after this one */ + bfd **after_bfd; /* New entries go after this one. */ bfd *current; bfd **current_ptr; @@ -1325,8 +1325,7 @@ replace_members (bfd *arch, char **files_to_move, bfd_boolean quick) /* Add to the end of the archive. */ after_bfd = get_pos_bfd (&arch->next, pos_end, NULL); - if (get_file_size (* files_to_move) > 0 - && ar_emul_append (after_bfd, *files_to_move, verbose)) + if (ar_emul_append (after_bfd, *files_to_move, verbose)) changed = TRUE; next_file:; -- 2.11.0