[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: [PATCH] #7 OS400/EBCDIC Port: Make svn_io_copy_file() CCSID insensitive.

From: Max Bowsher <maxb1_at_ukf.net>
Date: 2006-02-25 00:59:02 CET

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Mark Phippard wrote:
>>> On OS400 apr_file_copy() is sensitive to the source and destination
> files'
>>> CCSIDs in that it attempts to convert the contents of the source file
> from
>>> its CCSID to the CCSID of the destination file. If the files' CCSIDs
>>> differ from each other and/or the system CCSID, the destination file is
>>> likely to be corrupted.
>>>
>> That just made _me_ jump out the window. Luckily I'm on the second
>> floor, it was only a 6m drop.
>
> I do not know if you were joking or not, in response to Paul's comment
> about Julian, but we checked with IBM on this function and they are just
> implementing the exact function from the normal APR. APR does not open
> either of the files as binary, so on OS/400 that means it will try to
> translate the contents as it is Read and Written.
>
> I guess other platforms do not have this issue? I thought there were some
> differences in text and binary mode though, doesn't it effect line endings
> or something? Why would the APR function never corrupt files on other
> platforms? Why does APR not have a binary copy option? My guess, is that
> is _is_ binary on other platforms, but if that is the case, why doesn't it
> just specify APR_BINARY when it opens the files?

Good question. I've locally patched the Cygwin port, adding APR_BINARY
inside apr_file_transfer_contents().

Hmm. I really ought to get that merged upstream, especially now I'm an
APR committer now.

Max.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (Cygwin)

iD8DBQFD/53GfFNSmcDyxYARAu96AKCI8NIiNdP9bFLwn2iRbNkpvRv7yACgpN49
3DILfGv5F5tMtkJ5Wc5bK+c=
=nbXr
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Sat Feb 25 01:01:13 2006

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.