public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
* PR31314, chew crashing on use of uninitialized value
@ 2024-01-29 23:17 Alan Modra
  0 siblings, 0 replies; only message in thread
From: Alan Modra @ 2024-01-29 23:17 UTC (permalink / raw)
  To: binutils

The "drop" call in wrap_comment already increments pc.  Defining DOCDD
in proto.str is a warning fix.

	PR 31314
	* chew.c (wrap_comment): Don't increment pc.
	* proto.str (DOCDD): Define.

diff --git a/bfd/doc/chew.c b/bfd/doc/chew.c
index 28c8072c272..842d4153005 100644
--- a/bfd/doc/chew.c
+++ b/bfd/doc/chew.c
@@ -541,8 +541,6 @@ wrap_comment (void)
 
   overwrite_string (tos - 1, &out);
   drop ();
-
-  pc++;
 }
 
 /* Mod tos so that only lines with leading dots remain */
diff --git a/bfd/doc/proto.str b/bfd/doc/proto.str
index ee06c31fa7c..9a56397d719 100644
--- a/bfd/doc/proto.str
+++ b/bfd/doc/proto.str
@@ -166,6 +166,7 @@
 : SUBSUBSECTION ignore ;
 : INODE ignore ;
 : DESCRIPTION ignore ;
+: DOCDD ignore ;
 : ENDDD EXTERNAL ;
 : FUNCTION EXTERNAL ;
 : INTERNAL_FUNCTION INTERNAL ;

-- 
Alan Modra
Australia Development Lab, IBM

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

only message in thread, other threads:[~2024-01-29 23:17 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-01-29 23:17 PR31314, chew crashing on use of uninitialized value 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).