This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
Re: gas attempting to assemble non-existent file
>>> Alan Modra <amodra@bigpond.net.au> 13.09.06 10:07 >>>
>On Wed, Sep 13, 2006 at 07:56:32AM +0100, Jan Beulich wrote:
>> >@@ -248,10 +246,8 @@ input_file_give_next_buffer (char *where
>> > else
>> > {
>> > if (fclose (f_in))
>> >- {
>> >- bfd_set_error (bfd_error_system_call);
>> >- as_perror (_("Can't close %s"), file_name);
>> >- }
>> >+ as_bad (_("can't close %s: %s"), file_name, xstrerror (errno));
>> >+
>> > f_in = (FILE *) 0;
>> > return_value = 0;
>> > }
>>
>> Couldn't this be just as_warn()?
>
>I wrote it that way at first, then decided as_bad is probably better.
>An error from fclose might be due to failure to flush file buffers.
But we're talking about a file being read here, so there shouldn't be
any associated flushes (and even if there would be, they wouldn't
affect the produced output).
Jan