texinfo-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[7403] parsetexi update


From: gavinsmith0123
Subject: [7403] parsetexi update
Date: Wed, 21 Sep 2016 14:16:41 +0000 (UTC)

Revision: 7403
          http://svn.sv.gnu.org/viewvc/?view=rev&root=texinfo&revision=7403
Author:   gavin
Date:     2016-09-21 14:16:41 +0000 (Wed, 21 Sep 2016)
Log Message:
-----------
parsetexi update

Modified Paths:
--------------
    trunk/tp/parsetexi/api.c

Modified: trunk/tp/parsetexi/api.c
===================================================================
--- trunk/tp/parsetexi/api.c    2016-09-21 13:52:27 UTC (rev 7402)
+++ trunk/tp/parsetexi/api.c    2016-09-21 14:16:41 UTC (rev 7403)
@@ -696,18 +696,28 @@
 
       STORE("merged_in", newSVpv (ultimate->name, 0));
 
+      if (i->contained_hv)
+        {
+          hv_delete (i->hv,
+                     "contained_indices", strlen ("contained_indices"),
+                     G_DISCARD);
+          i->contained_hv = 0;
+        }
+
       /* See also code in end_line.c (parse_line_command_args) <CM_synindex>.
          FIXME: Do we need to keep the original values of contained_indices?
          I don't think so. */
     }
-
-  if (!i->contained_hv)
+  else
     {
-      i->contained_hv = newHV ();
-      STORE("contained_indices", newRV_inc ((SV *)(HV *) i->contained_hv));
+      if (!i->contained_hv)
+        {
+          i->contained_hv = newHV ();
+          STORE("contained_indices", newRV_inc ((SV *)(HV *) i->contained_hv));
+        }
+      /* Record that this index "contains itself". */
+      hv_store (i->contained_hv, i->name, strlen (i->name), newSViv(1), 0);
     }
-  /* Record that this index "contains itself". */
-  hv_store (i->contained_hv, i->name, strlen (i->name), newSViv(1), 0);
 
   if (i->index_number > 0)
     {




reply via email to

[Prev in Thread] Current Thread [Next in Thread]