% ./b === Candidate changes: >>> The r1491816 group: r1491816, r1494089 Add two additional options to interactive file merge. +1: stsp, danielsh Go ahead? n >>> The 1.8.x-r1497310-partial branch: r1497310 ^/subversion/branches/1.8.x-r1497310-partial Backport 'svn help cleanup' improvements made in r1497310. +1: stsp, danielsh Go ahead? n >>> The r1492264 group: r1492264 Fix wrong character encoding handling of generic error messages in JavaHL +1: brane Go ahead? y Would have committed: [[[ M . M subversion/bindings/javahl/native/JNIUtil.cpp M STATUS (not shown in the diff) Merge r1492264 from trunk: * r1492264 Fix wrong character encoding handling of generic error messages in JavaHL Justification: Fixes a confusing bug where the generic error message generated by JavaHL is mangled due to wrong encoding, but the more specific messages generated by the native libraries are legible. Votes: +1: brane ]]] Shall I open a subshell? [ydN] d Index: subversion/bindings/javahl/native/JNIUtil.cpp =================================================================== --- subversion/bindings/javahl/native/JNIUtil.cpp (revision 1499419) +++ subversion/bindings/javahl/native/JNIUtil.cpp (working copy) @@ -871,7 +871,21 @@ void JNIUtil::assembleErrorMessage(svn_error_t *er buffer.append(svn_strerror(err->apr_err, errbuf, sizeof(errbuf))); /* Otherwise, this must be an APR error code. */ else - buffer.append(apr_strerror(err->apr_err, errbuf, sizeof(errbuf))); + { + /* Messages coming from apr_strerror are in the native + encoding, it's a good idea to convert them to UTF-8. */ + const char* utf8_message; + apr_strerror(err->apr_err, errbuf, sizeof(errbuf)); + svn_error_t* utf8_err = svn_utf_cstring_to_utf8( + &utf8_message, errbuf, err->pool); + if (utf8_err) + { + /* Use fuzzy transliteration instead. */ + svn_error_clear(utf8_err); + utf8_message = svn_utf_cstring_from_utf8_fuzzy(errbuf, err->pool); + } + buffer.append(utf8_message); + } buffer.append("\n"); } if (err->message) Index: . =================================================================== --- . (revision 1499419) +++ . (working copy) Property changes on: . ___________________________________________________________________ Modified: svn:mergeinfo Merged /subversion/trunk:r1492264 Shall I open a subshell? [ydN] ^C Revert? y Reverted '.' Reverted 'subversion/bindings/javahl/native/JNIUtil.cpp' %