From commits-return-9430-apmail-commons-commits-archive=commons.apache.org@commons.apache.org Sun Nov 08 05:37:46 2009 Return-Path: Delivered-To: apmail-commons-commits-archive@minotaur.apache.org Received: (qmail 64849 invoked from network); 8 Nov 2009 05:37:46 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 8 Nov 2009 05:37:46 -0000 Received: (qmail 8243 invoked by uid 500); 8 Nov 2009 05:37:46 -0000 Delivered-To: apmail-commons-commits-archive@commons.apache.org Received: (qmail 8162 invoked by uid 500); 8 Nov 2009 05:37:45 -0000 Mailing-List: contact commits-help@commons.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@commons.apache.org Delivered-To: mailing list commits@commons.apache.org Received: (qmail 8153 invoked by uid 99); 8 Nov 2009 05:37:45 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 08 Nov 2009 05:37:45 +0000 X-ASF-Spam-Status: No, hits=-2.6 required=5.0 tests=AWL,BAYES_00 X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 08 Nov 2009 05:37:43 +0000 Received: by eris.apache.org (Postfix, from userid 65534) id 744552388906; Sun, 8 Nov 2009 05:37:23 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r833832 - in /commons/proper/vfs/branches/VFS281: core/src/main/java/org/apache/commons/vfs/provider/webdav/WebdavFileObject.java xdocs/changes.xml Date: Sun, 08 Nov 2009 05:37:23 -0000 To: commits@commons.apache.org From: rgoers@apache.org X-Mailer: svnmailer-1.0.8 Message-Id: <20091108053723.744552388906@eris.apache.org> Author: rgoers Date: Sun Nov 8 05:37:23 2009 New Revision: 833832 URL: http://svn.apache.org/viewvc?rev=833832&view=rev Log: Apply patch for VFS-261 Modified: commons/proper/vfs/branches/VFS281/core/src/main/java/org/apache/commons/vfs/provider/webdav/WebdavFileObject.java commons/proper/vfs/branches/VFS281/xdocs/changes.xml Modified: commons/proper/vfs/branches/VFS281/core/src/main/java/org/apache/commons/vfs/provider/webdav/WebdavFileObject.java URL: http://svn.apache.org/viewvc/commons/proper/vfs/branches/VFS281/core/src/main/java/org/apache/commons/vfs/provider/webdav/WebdavFileObject.java?rev=833832&r1=833831&r2=833832&view=diff ============================================================================== --- commons/proper/vfs/branches/VFS281/core/src/main/java/org/apache/commons/vfs/provider/webdav/WebdavFileObject.java (original) +++ commons/proper/vfs/branches/VFS281/core/src/main/java/org/apache/commons/vfs/provider/webdav/WebdavFileObject.java Sun Nov 8 05:37:23 2009 @@ -21,7 +21,7 @@ import org.apache.commons.httpclient.HttpMethod; import org.apache.commons.httpclient.URIException; import org.apache.commons.httpclient.methods.RequestEntity; -import org.apache.commons.httpclient.methods.StringRequestEntity; +import org.apache.commons.httpclient.methods.ByteArrayRequestEntity; import org.apache.commons.httpclient.util.DateUtil; import org.apache.commons.vfs.provider.URLFileName; import org.apache.commons.vfs.provider.DefaultFileContent; @@ -562,7 +562,7 @@ */ protected void onClose() throws IOException { - RequestEntity entity = new StringRequestEntity(out.toString()); + RequestEntity entity = new ByteArrayRequestEntity(((ByteArrayOutputStream) out).toByteArray()); URLFileName fileName = (URLFileName) getName(); String urlStr = urlString(fileName); WebdavFileSystemOptions opts = fileSystem.getFileSystemOptions(); Modified: commons/proper/vfs/branches/VFS281/xdocs/changes.xml URL: http://svn.apache.org/viewvc/commons/proper/vfs/branches/VFS281/xdocs/changes.xml?rev=833832&r1=833831&r2=833832&view=diff ============================================================================== --- commons/proper/vfs/branches/VFS281/xdocs/changes.xml (original) +++ commons/proper/vfs/branches/VFS281/xdocs/changes.xml Sun Nov 8 05:37:23 2009 @@ -23,6 +23,9 @@ + + WebDAV upload corrupts binary files + add ProviderTestConfig.getDefaultFileSystemManager() method