cURL / Mailing Lists / curl-library / Single Mail


Re: Cannot PUT to a collection - webdav problem

From: Michael Wood <>
Date: Thu, 26 Feb 2009 10:22:46 +0200

On Wed, Feb 25, 2009 at 11:17 PM, Felix Hammer <> wrote:
> Hi
> I tried to upload a file to apache2/webdav server via libcurl. Therefore i
> took the http-put.c example.
> When i do: ./httpputexample myFile http://myserver/webdav/ i always get:
> < HTTP/1.1 409 Conflict
> When i use the command line curl with the same file and same server like:
> "curl -T myfile http://myserver/webdav/" everything works fine:
> Does anybody know what i'am doing wrong with the example?

No, but you can try adding --libcurl to your curl command line.
According to the curl documentation:

  --libcurl <file>
        Append this option to any ordinary curl command line, and you
        will get a libcurl-using source code written to the file that
        does the equivalent operation of what your command line opera-
        tion does!

Michael Wood <>
Received on 2009-02-26