[silme] properties parser ignores entities which beginns with spaces

RESOLVED FIXED

Status

Mozilla Localizations
Infrastructure
RESOLVED FIXED
9 years ago
9 years ago

People

(Reporter: adriank, Unassigned)

Tracking

Firefox Tracking Flags

(Not tracked)

Details

(Whiteboard: [compare-locales compat])

(Reporter)

Description

9 years ago
The properties parser in Silme ignores entities which beginns with spaces like

" stateBlockedPolicy=This download has been blocked by your Security Zone Policy" 

in toolkit/locales/en-US/chrome/mozapps/downloads/downloads.properties.

I think that we need to change this regexp:
entityPattern = re.compile('^([^#!\s\r\n][^=:\r\n]*?)\s*[:=][ \t]*(.*?)[ \t]*$',re.M)
to solve the problem.
(Reporter)

Updated

9 years ago
Whiteboard: [compare-locales compat]
Oh, sure. Please, take a look at Pike's regexp for properties and also make sure that your regexp covers multiline properties.
Then give me a patch and we're done :)
(Reporter)

Updated

9 years ago
Blocks: 452311
(Reporter)

Comment 2

9 years ago
thanks Gandalf :)
Status: NEW → RESOLVED
Last Resolved: 9 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.