Fix a build problem when using FreeBSD 12.

* ar.c (write_archive): Cast iostream pointer to FILE *.
	* arsup.c (ar_save): Likewise.
	* objcopy.c (copy_file): Likewise.
This commit is contained in:
Sebastian Huber
2020-12-11 13:27:45 +00:00
committed by Nick Clifton
parent 9cd7a95a2b
commit b143e2d506
4 changed files with 9 additions and 3 deletions

View File

@@ -3745,7 +3745,7 @@ copy_file (const char *input_filename, const char *output_filename, int ofd,
/* To allow us to do "strip *" without dying on the first
non-object file, failures are nonfatal. */
ibfd = bfd_openr (input_filename, input_target);
if (ibfd == NULL || fstat (fileno (ibfd->iostream), in_stat) != 0)
if (ibfd == NULL || fstat (fileno ((FILE *) ibfd->iostream), in_stat) != 0)
{
bfd_nonfatal_message (input_filename, NULL, NULL, NULL);
status = 1;