public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
* alpha-coff: unitialised read
@ 2020-03-31  6:27 Alan Modra
  0 siblings, 0 replies; only message in thread
From: Alan Modra @ 2020-03-31  6:27 UTC (permalink / raw)
  To: binutils

	* coff-alpha.c (alpha_ecoff_get_elt_at_filepos): Correct bfd_bread
	return value check.

diff --git a/bfd/coff-alpha.c b/bfd/coff-alpha.c
index b86a8a259b..4fd3b5c488 100644
--- a/bfd/coff-alpha.c
+++ b/bfd/coff-alpha.c
@@ -2130,7 +2130,7 @@ alpha_ecoff_get_elt_at_filepos (bfd *archive, file_ptr filepos)
 		n = dict[h];
 	      else
 		{
-		  if (! bfd_bread (&n, (bfd_size_type) 1, nbfd))
+		  if (bfd_bread (&n, 1, nbfd) != 1)
 		    goto error_return;
 		  dict[h] = n;
 		}

-- 
Alan Modra
Australia Development Lab, IBM

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2020-03-31  6:27 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-03-31  6:27 alpha-coff: unitialised read Alan Modra

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).