summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBruno Haible <bruno@clisp.org>2009-11-28 15:14:04 +0100
committerBruno Haible <bruno@clisp.org>2009-11-28 15:14:04 +0100
commita02937e79d1eb3ae204e98c5614154be10276d3a (patch)
tree2bd6509968531572db7675170b7b64f4bc8e1a24
parentf50acae2010a97984a1bc9903a4567d87198da79 (diff)
downloadexternal_gettext-a02937e79d1eb3ae204e98c5614154be10276d3a.zip
external_gettext-a02937e79d1eb3ae204e98c5614154be10276d3a.tar.gz
external_gettext-a02937e79d1eb3ae204e98c5614154be10276d3a.tar.bz2
Fix a bug in the Perl extractor.
-rw-r--r--gettext-tools/src/ChangeLog5
-rw-r--r--gettext-tools/src/x-perl.c5
2 files changed, 9 insertions, 1 deletions
diff --git a/gettext-tools/src/ChangeLog b/gettext-tools/src/ChangeLog
index d67bdbe..678a861 100644
--- a/gettext-tools/src/ChangeLog
+++ b/gettext-tools/src/ChangeLog
@@ -1,3 +1,8 @@
+2009-11-28 Bruno Haible <bruno@clisp.org>
+
+ * x-perl.c (extract_variable): Fix tp->type when returning at EOF.
+ Reported by Guido Flohr <guido@imperia.bg>.
+
2009-11-15 Bruno Haible <bruno@clisp.org>
* x-python.c: Update comments regarding PEP 0263.
diff --git a/gettext-tools/src/x-perl.c b/gettext-tools/src/x-perl.c
index 221108d..1830a10 100644
--- a/gettext-tools/src/x-perl.c
+++ b/gettext-tools/src/x-perl.c
@@ -1381,7 +1381,10 @@ extract_variable (message_list_ty *mlp, token_ty *tp, int first)
if (extract_balanced (mlp, token_type_rbrace, true, false,
null_context, null_context_list_iterator,
1, arglist_parser_alloc (mlp, NULL)))
- return;
+ {
+ tp->type = token_type_eof;
+ return;
+ }
buffer[bufpos++] = c;
}
else