Bug 337724 - Places `#, fuzzy' in a wrong place causing msgfmt's syntax errors
Summary: Places `#, fuzzy' in a wrong place causing msgfmt's syntax errors
Status: RESOLVED FIXED
Alias: None
Product: lokalize
Classification: Applications
Component: general (show other bugs)
Version: unspecified
Platform: Debian unstable Linux
: NOR normal
Target Milestone: ---
Assignee: Nick Shaforostoff
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-07-23 12:12 UTC by Maximiliano Curia
Modified: 2014-12-21 05:31 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:


Attachments
Test file (636 bytes, text/x-gettext-translation)
2014-07-23 12:13 UTC, Maximiliano Curia
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Maximiliano Curia 2014-07-23 12:12:43 UTC
Originally reported in the debian bts: https://bugs.debian.org/726796

Hi,

When message string contain a comment, lokalize places `fuzzy' marker
after it, which causes any further msg* commands to report  `syntax
error'.

Example to reproduce the issue:

Please see the attached file. Before running lokalize, msgfmt displays: 
	> LC_ALL=C msgfmt --statistics test.po
	0 translated messages, 1 fuzzy translation.

Now, please run 
	> lokalize ./test.po
and do the three following actions inside it:
 	1. first mark the entry as translated: Edit->Translated->Ready
	2. than mark it as untranslated      : Edit->Translated->Needs Review
	3. finally save the file             : File->Save

After doing that msgfmt fails:

	> LC_ALL=C msgfmt --statistics test.po
	test.po:20:1: syntax error
	msgfmt: found 1 fatal error

Still reproduceable in 4.13.1.
Comment 1 Maximiliano Curia 2014-07-23 12:13:34 UTC
Created attachment 87898 [details]
Test file
Comment 2 Nick Shaforostoff 2014-12-21 05:31:43 UTC
Git commit 41bff57451b4521482952a014ed06526f0651f24 by Nick Shaforostoff.
Committed on 21/12/2014 at 07:30.
Pushed by shaforo into branch 'master'.
ensure msgfmt likes our output

Maximiliano Curia: thank you for providing a test file!

M  +11   -0    src/catalog/gettext/catalogitem.cpp
M  +5    -5    src/editortab.cpp

http://commits.kde.org/lokalize/41bff57451b4521482952a014ed06526f0651f24