[Translation] PoFileLoader should use stripcslashes instead of stripslashes #5427

Closed
goetas opened this Issue Sep 4, 2012 · 0 comments

Projects

None yet

2 participants

@goetas
goetas commented Sep 4, 2012

PoFileLoader::addMessage() uses both stripslashes and stripcslashes to unescape translated strings, but PoFileDumper uses only addcslashes to escape strings.

  • PoFileLoader should use only stripcslashes to unescape strings (according with PoFileDumper, that generates correct PO files).
  • $item['ids']['singular'] should be unescaped with stripcslashes (msgid are equivalent to msgstr strings).
@fabpot fabpot added the Easy Pick label Apr 28, 2014
@umpirsky umpirsky added a commit to umpirsky/symfony that referenced this issue Apr 29, 2014
@umpirsky umpirsky Fixed issue #5427 d497099
@fabpot fabpot added a commit that referenced this issue Apr 30, 2014
@umpirsky umpirsky Fixed issue #5427 f308f52
@fabpot fabpot added a commit that referenced this issue Apr 30, 2014
@fabpot fabpot bug #10815 Fixed issue #5427 (umpirsky)
This PR was submitted for the master branch but it was merged into the 2.3 branch instead (closes #10815).

Discussion
----------

Fixed issue #5427

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #5427
| License       | MIT

Commits
-------

f308f52 Fixed issue #5427
93926ca
@fabpot fabpot closed this Apr 30, 2014
@fabpot fabpot added a commit that referenced this issue May 12, 2014
@fabpot fabpot Merge branch '2.3' into 2.4
* 2.3:
  [Console]Improve formatter for double-width character
  Lower mbstring dep, remove it for Yaml and CssSelector components
  [Security] Add check for supported attributes in AclVoter
  [Form] Fixed TrimListenerTest as of PHP 5.5
  Added more IDE links
  [DependencyInjection] Fix parameter description in ConfigurationExtensionInterface
  [Finder] fixed typehint of the Finder::addAdapter() method
  [TwigBridge][Transchoice] set %count% from the current context.
  [DependencyInjection] Fix travis unit tests
  Update PHPUnit before run
  [Validator] fixed wrong test
  [WebProfilerBundle] added test case for #10773
  [WebProfilerBundle] fixed profiler homepage, fixed #10806
  [WebProfilerBundle] Added test case for #10806
  changed travis to run on the nightly builds of HHVM until everything gets stable
  Fixed issue #5427
  Allow URLs that don't contain a path

Conflicts:
	.travis.yml
934cd28
@fabpot fabpot added a commit that referenced this issue May 12, 2014
@fabpot fabpot Merge branch '2.4'
* 2.4:
  Lower mbstring dependency
  [Console]Improve formatter for double-width character
  Lower mbstring dep, remove it for Yaml and CssSelector components
  [Security] Add check for supported attributes in AclVoter
  [Form] Fixed TrimListenerTest as of PHP 5.5
  Added more IDE links
  [DependencyInjection] Fix parameter description in ConfigurationExtensionInterface
  [Security] fixed wrong PHPDoc of the TokenGeneratorInterface
  [Finder] fixed typehint of the Finder::addAdapter() method
  [TwigBridge][Transchoice] set %count% from the current context.
  [DependencyInjection] Fix travis unit tests
  Update PHPUnit before run
  [Validator] fixed wrong test
  [WebProfilerBundle] added test case for #10773
  [WebProfilerBundle] fixed profiler homepage, fixed #10806
  [WebProfilerBundle] Added test case for #10806
  changed travis to run on the nightly builds of HHVM until everything gets stable
  Fixed issue #5427
  Allow URLs that don't contain a path

Conflicts:
	.travis.yml
	src/Symfony/Component/Console/Application.php
7e4b4a7
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment