]> git.ipfire.org Git - thirdparty/gettext.git/commitdiff
xgettext: Fix parsing of XML tags.
authorBruno Haible <bruno@clisp.org>
Sun, 29 Sep 2019 12:35:37 +0000 (14:35 +0200)
committerBruno Haible <bruno@clisp.org>
Mon, 13 Apr 2020 11:20:48 +0000 (13:20 +0200)
* gettext-tools/src/x-javascript.c (phase5_get): Fix lexical_context after
decrementing xml_element_depth.

gettext-tools/src/x-javascript.c

index b34d92eaa5f0820c480064cf638184ffc642350c..e13d8d8b0c8a5e3f3ad1766636d597717e15de84 100644 (file)
@@ -1325,7 +1325,7 @@ phase5_get (token_ty *tp)
                   break;
 
                 case lc_xml_close_tag:
-                  if (xml_element_depth-- > 0)
+                  if (--xml_element_depth > 0)
                     lexical_context = lc_xml_content;
                   else
                     lexical_context = lc_outside;
@@ -1350,7 +1350,7 @@ phase5_get (token_ty *tp)
                   c = phase2_getc ();
                   if (c == '>')
                     {
-                      if (xml_element_depth-- > 0)
+                      if (--xml_element_depth > 0)
                         lexical_context = lc_xml_content;
                       else
                         lexical_context = lc_outside;