summaryrefslogtreecommitdiffstats
path: root/gettext-tools/src/x-c.c
diff options
context:
space:
mode:
Diffstat (limited to 'gettext-tools/src/x-c.c')
-rw-r--r--gettext-tools/src/x-c.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/gettext-tools/src/x-c.c b/gettext-tools/src/x-c.c
index cfff2d3..d38bc6a 100644
--- a/gettext-tools/src/x-c.c
+++ b/gettext-tools/src/x-c.c
@@ -662,7 +662,9 @@ phase4_getc ()
c = phase3_getc ();
if (c == '\n' || c == EOF)
break;
- comment_add (c);
+ /* We skip all leading white space, but not EOLs. */
+ if (!(buflen == 0 && (c == ' ' || c == '\t')))
+ comment_add (c);
}
comment_line_end (0);
last_comment_line = newline_count;