Code review comment for lp:~songofacandy/bzr/fix-523746-dev

Revision history for this message
methane (songofacandy) wrote :

OK.

1. On Windows.
Some diff application doesn't receive command line argument as a UTF-16 string
but as a string encoded with current codepage.
In this situation, passing Unicode argument to child process may fail
when the file path
contains character that is not be able to encode with current codepage.
So, we should use only chars those are able to encode with current codepage as a
temporary file.

2. On Unix.
All application may receive commandline argument as just bytes. So we can pass
any path as a argument.
But, GUI diff tool may be not able to show such filepath. So we should
use string
that is able to encode with current locale as a temporary file, too.

My fix removes chars those are not able to encode with current codepage/locale.
And force to use temporary file when checkouted file contains such chars as a
path.

On Thu, May 12, 2011 at 4:23 PM, John Arbash Meinel
<email address hidden> wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> On 5/6/2011 8:28 PM, INADA Naoki wrote:
>> INADA Naoki has proposed merging lp:~songofacandy/bzr/fix-523746-dev into lp:bzr.
>>
>> Requested reviews:
>>   John A Meinel (jameinel)
>>   Alexander Belchenko (bialix)
>>   Gary van der Merwe (garyvdm)
>>   Martin [gz] (gz)
>>   Vincent Ladeuil (vila)
>>   bzr-core (bzr-core)
>> Related bugs:
>>   Bug #523746 in Bazaar: "crash with winmerge in cp932 japanese character"
>>   https://bugs.launchpad.net/bzr/+bug/523746
>>
>> For more details, see:
>> https://code.launchpad.net/~songofacandy/bzr/fix-523746-dev/+merge/20537
>
> Can you give a little bit more background in your merge proposal? I know
> there is a bug linked, but describing what you are doing makes it easier
> to understand the diff.
>
>  review: needsinfo
>
> John
> =:->
>
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.4.9 (Cygwin)
> Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
>
> iEYEARECAAYFAk3Liw0ACgkQJdeBCYSNAAOxzACguDKS9ztLjW6NJ54ii0fWIffL
> dgkAoJ8kAv8ws8Atxw+O4d4o3ke54TMa
> =u/ie
> -----END PGP SIGNATURE-----
>

--
INADA Naoki  <email address hidden>

« Back to merge proposal