From: Nick Clifton Date: Thu, 30 Jun 2011 15:08:17 +0000 (+0000) Subject: PR binutils/12558 X-Git-Tag: sid-snapshot-20110701~12 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=75d5a45f82040ef3e85023926a1840e27f127d73;p=external%2Fbinutils.git PR binutils/12558 * ar.c (main): When asked to move members in an archive that is being created, ignore the move request. --- diff --git a/binutils/ChangeLog b/binutils/ChangeLog index 69140c2..b34cd88 100644 --- a/binutils/ChangeLog +++ b/binutils/ChangeLog @@ -1,3 +1,9 @@ +2011-06-30 Nick Clifton + + PR binutils/12558 + * ar.c (main): When asked to move members in an archive that is + being created, ignore the move request. + 2011-06-29 Nick Clifton * readelf.c (get_section_type_name): When displaying an unknown diff --git a/binutils/ar.c b/binutils/ar.c index 42cc0c6..f8c977a 100644 --- a/binutils/ar.c +++ b/binutils/ar.c @@ -745,11 +745,17 @@ main (int argc, char **argv) break; case move: - if (files != NULL) - move_members (arch, files); - else - output_filename = NULL; - break; + /* PR 12558: Creating and moving at the same time does + not make sense. Just create the archive instead. */ + if (! silent_create) + { + if (files != NULL) + move_members (arch, files); + else + output_filename = NULL; + break; + } + /* Fall through. */ case replace: case quick_append: