Documentation for the new mtag commands
[deliverable/binutils-gdb.git] / libctf / ctf-util.c
index ab34bc0732eef95ae53642f63afa609a2949f39e..4f126ba0ee464770dc86d5514479b0abb11da598 100644 (file)
@@ -1,5 +1,5 @@
 /* Miscellaneous utilities.
-   Copyright (C) 2019-2020 Free Software Foundation, Inc.
+   Copyright (C) 2019-2021 Free Software Foundation, Inc.
 
    This file is part of libctf.
 
@@ -283,9 +283,8 @@ ctf_next_destroy (ctf_next_t *i)
 
   if (i->ctn_iter_fun == (void (*) (void)) ctf_dynhash_next_sorted)
     free (i->u.ctn_sorted_hkv);
-  if (i->ctn_iter_fun == (void (*) (void)) ctf_symbol_next
-      && i->cu.ctn_fp->ctf_flags & LCTF_RDWR)
-    ctf_next_destroy (i->u.ctn_next);
+  if (i->ctn_next)
+    ctf_next_destroy (i->ctn_next);
   free (i);
 }
 
This page took 0.026971 seconds and 4 git commands to generate.