public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
* Tidy some global bfd state used by gas
@ 2023-01-11  8:37 Alan Modra
  0 siblings, 0 replies; only message in thread
From: Alan Modra @ 2023-01-11  8:37 UTC (permalink / raw)
  To: binutils

	* subsegs.c (subsegs_end): Clear abs and und userdata.

diff --git a/gas/subsegs.c b/gas/subsegs.c
index c834ee2157e..ae42b4e76d9 100644
--- a/gas/subsegs.c
+++ b/gas/subsegs.c
@@ -50,6 +50,8 @@ subsegs_end (struct obstack **obs)
   for (; *obs; obs++)
     _obstack_free (*obs, NULL);
   _obstack_free (&frchains, NULL);
+  bfd_set_section_userdata (bfd_abs_section_ptr, NULL);
+  bfd_set_section_userdata (bfd_und_section_ptr, NULL);
 }
 \f
 static void

-- 
Alan Modra
Australia Development Lab, IBM

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

only message in thread, other threads:[~2023-01-11  8:37 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-01-11  8:37 Tidy some global bfd state used by gas 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).