Merge lp:~paul-lucas/zorba/bug-942808 into lp:zorba

Proposed by Paul J. Lucas
Status: Merged
Approved by: Paul J. Lucas
Approved revision: 10683
Merged at revision: 10683
Proposed branch: lp:~paul-lucas/zorba/bug-942808
Merge into: lp:zorba
Diff against target: 30 lines (+13/-7)
1 file modified
src/util/icu_streambuf.cpp (+13/-7)
To merge this branch: bzr merge lp:~paul-lucas/zorba/bug-942808
Reviewer Review Type Date Requested Status
Matthias Brantner Approve
Paul J. Lucas Approve
Review via email: mp+95027@code.launchpad.net

Commit message

Fixed bug 942808.

Description of the change

Fixed bug 942808.

To post a comment you must log in.
Revision history for this message
Paul J. Lucas (paul-lucas) :
review: Approve
Revision history for this message
Matthias Brantner (matthias-brantner) wrote :

It's kind of cheating. The question is why the ICU comparison didn't work?

Revision history for this message
Matthias Brantner (matthias-brantner) :
review: Approve
Revision history for this message
Zorba Build Bot (zorba-buildbot) wrote :
Revision history for this message
Zorba Build Bot (zorba-buildbot) wrote :

The attempt to merge lp:~paul-lucas/zorba/bug-942808 into lp:zorba failed. Below is the output from the failed tests.

CMake Error at /home/ceej/zo/testing/zorbatest/tester/TarmacLander.cmake:274 (message):
  Validation queue job bug-942808-2012-02-28T19-46-04.742Z is finished. The
  final status was:

  1 tests did not succeed - changes not commited.

Error in read script: /home/ceej/zo/testing/zorbatest/tester/TarmacLander.cmake

Revision history for this message
Zorba Build Bot (zorba-buildbot) wrote :
Revision history for this message
Zorba Build Bot (zorba-buildbot) wrote :

Validation queue job bug-942808-2012-02-28T20-38-04.132Z is finished. The final status was:

All tests succeeded!

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'src/util/icu_streambuf.cpp'
--- src/util/icu_streambuf.cpp 2012-02-20 18:12:06 +0000
+++ src/util/icu_streambuf.cpp 2012-02-28 19:36:18 +0000
@@ -100,13 +100,19 @@
100 return conv;100 return conv;
101}101}
102102
103bool icu_streambuf::is_necessary( char const *charset ) {103bool icu_streambuf::is_necessary( char const *cc_charset ) {
104 //104 //
105 // Checking for "US-ASCII" explicitly isn't necessary since ICU knows about105 // Apparently, ucnv_compareNames() doesn't consider "US-ASCII" an alias for
106 // aliases.106 // "ASCII", so check for "US-ASCII" ourselves.
107 //107 //
108 return ucnv_compareNames( charset, "ASCII" )108 zstring charset( cc_charset );
109 && ucnv_compareNames( charset, "UTF-8" );109 ascii::trim_whitespace( charset );
110 ascii::to_upper( charset );
111 if ( charset == "US-ASCII" )
112 cc_charset += 3; // skip "US-"
113
114 return ucnv_compareNames( cc_charset, "ASCII" )
115 && ucnv_compareNames( cc_charset, "UTF-8" );
110}116}
111117
112bool icu_streambuf::is_supported( char const *charset ) {118bool icu_streambuf::is_supported( char const *charset ) {

Subscribers

People subscribed via source and target branches