On Sun, Jun 8, 2008 at 2:46 AM, Alan Bateman <[EMAIL PROTECTED]> wrote: > Martin Buchholz wrote: >> Perhaps it is easiest to implement append mode by using the current >> code that uses FileOutputStream and extracts the HANDLE from that, >> but at the last moment replacing the HANDLE with a new HANDLE >> that has FILE_WRITE_DATA turned off before calling CreateProcess. >> > > Assuming you are thinking of ReOpenFile then we would still need a solution > for Windows XP because that Win32 needs Windows Server 2003 or newer.
Obviously my memory is not what it used to me. Your comment rings a bell. I now recall having come to a similar conclusion when I investigated this originally. Perhaps we should have a hybrid of the two append mode implementations where opening a FileOutputStream in append mode works as it did in JDK 6, but we provide an extra non-public way to construct a FileOutputStream that would open using FILE_APPEND_DATA as in current JDK7. This secret constructor would only be used by the process creation code. That would result in minimal changes to the process code. Martin
