Re: Segmentation Fault with pthreads and https

2012-02-13 Thread Lars Nilsson
On Mon, Feb 13, 2012 at 3:12 PM, Jan Kammerath wrote: > Dearest Friends of cURL, > > I am having issues with libcurl in c++ processing https requests > within pthreads. Whenever I call it synchronously it works fine for > me, but calling it within pthreads it throws segmentation faults. My > code

Re: Curl + Visual Studio 2010 - Application fails to initialize

2012-02-13 Thread Poul Thomas Lomholt
Apparently the prebuilt curl package requires the VS2008 C runtime (msvcr90.dll); several of the .dll's in the dist declare the following in their manifest: Microsoft.VC90.CRT" version="9.0.21022.8" - try installing those (or a later 9.0.x build) on your laptop and it may solve your problem... R

Re: Curl + Visual Studio 2010 - Application fails to initialize

2012-02-13 Thread Lars Nilsson
On Mon, Feb 13, 2012 at 4:04 PM, eli wrote: > Hi Lars, > > On both the PC and the laptop Dependency Walker can't find IESHIMS.DLL > and WER.DLL. It was my initial suspicion, that some DLLs are missing. > But since its the same DLLs on both machines I don't think this is the > reason. IESHIMS.DLL

Re: Segmentation Fault with pthreads and https

2012-02-13 Thread Steve H Truong
From: Jan Kammerath Sent: Monday, February 13, 2012 12:12 PM Subject: Segmentation Fault with pthreads and https > but I found the segmentation fault directly occurs within > "curl_easy_perform" Do you have a chance to put the process under debug (e.g., gdb) and see what the immediate cause

Re: [PATCH] Add configuration option to disable curl command's --libcurl option

2012-02-13 Thread Daniel Stenberg
On Sun, 5 Feb 2012, Colin Hogben wrote: This patch adds a configuration option, --disable-libcurl-option, which disables the --libcurl option of the curl command. This may be useful in e.g. embedded environments where the generation of C source code is not useful. Sorry for the delay, but n

Re: Curl + Visual Studio 2010 - Application fails to initialize

2012-02-13 Thread eli
Hi Gisle, Its Windows XP + SP3. On Mon, Feb 13, 2012 at 10:00 PM, Gisle Vanem wrote: > "eli" wrote: > >> There are two PCs i work on, both have the same versions of Windows >> and the same versions of Visual Studio. The first is desktop PC and >> the second is laptop. > > > It would be nice to

Re: Curl + Visual Studio 2010 - Application fails to initialize

2012-02-13 Thread eli
Hi Lars, On both the PC and the laptop Dependency Walker can't find IESHIMS.DLL and WER.DLL. It was my initial suspicion, that some DLLs are missing. But since its the same DLLs on both machines I don't think this is the reason. On Mon, Feb 13, 2012 at 9:33 PM, Lars Nilsson wrote: > On Mon, Fe

Segmentation Fault with pthreads and https

2012-02-13 Thread Jan Kammerath
Dearest Friends of cURL, I am having issues with libcurl in c++ processing https requests within pthreads. Whenever I call it synchronously it works fine for me, but calling it within pthreads it throws segmentation faults. My code is published under MPL and therefore it would be nice if someone c

Re: Curl + Visual Studio 2010 - Application fails to initialize

2012-02-13 Thread Gisle Vanem
"eli" wrote: There are two PCs i work on, both have the same versions of Windows and the same versions of Visual Studio. The first is desktop PC and the second is laptop. It would be nice to know which Windows that is? Loaded '..\Debug\curllib.dll', Binary was not built with debug informa

Re: Curl + Visual Studio 2010 - Application fails to initialize

2012-02-13 Thread Lars Nilsson
On Mon, Feb 13, 2012 at 1:51 PM, eli wrote: > I use the DLLs provided by libcurl-7.19.3-win32-ssl-msvc.zip within an > MFC project. I assume you have checked the dependencies of the dlls using Dependency Walker? Lars Nilsson --- Lis

Re: Multiple requests on Same CURL handle fails.

2012-02-13 Thread Daniel Stenberg
On Mon, 13 Feb 2012, Prabu RM wrote: *Issue:* Multiple request methods say HEAD & PUT in a single CURL reusing handle fails and throws errors like below. RequestTimeoutYour socket connection to the server was not read from or written to within the timeout period. So how long time is it betw

Re: [PATCH] curl tool: allow negative numbers as option values

2012-02-13 Thread Daniel Stenberg
On Sun, 12 Feb 2012, Alessandro Ghedini wrote: The attached patch removes the check inside str2num() that makes it accept only strings that start with a digit, which is wrong Thanks, pushed now! -- / daniel.haxx.se --- List adm

Curl + Visual Studio 2010 - Application fails to initialize

2012-02-13 Thread eli
I have a weird problem with libcurl and Visual Studio 2010. There are two PCs i work on, both have the same versions of Windows and the same versions of Visual Studio. The first is desktop PC and the second is laptop. I use the DLLs provided by libcurl-7.19.3-win32-ssl-msvc.zip within an MFC proj

RE: Avoid copying data in CURLOPT_WRITEFUNCTION callback

2012-02-13 Thread Aleksandar Lazic
On 13-02-2012 13:20, Daniel Stenberg wrote: On Mon, 13 Feb 2012, Yehezkel Horowitz wrote: I think that 'CURLcode curl_allocate_buffer_cb(char** buff, int* size)' which will be called by curl with the requested buffer size - would be easy to use API for this. Yes, I agree it could probably b

Re: [PATCH] Enable multiple files in test scripts

2012-02-13 Thread Colin Hogben
Daniel Stenberg wrote: With this series applied I get test failures on test 222, do you? Yes, I do too. I thought I had run the tests, but on second thoughts I may have confused myself when switching between different branch - sorry for wasting your time. The fail does however look like

Re: Avoid copying data in CURLOPT_WRITEFUNCTION callback

2012-02-13 Thread Konstantin Miller
An interface as suggested by Yehezkel would be really great! It would give the application the flexibility to implement its own memory management. It still would be very helpful, even if the minimum buffer size would be 2 x 16K, as pointed out by Daniel. I think that if you are targeting a video s

Re: Avoid copying data in CURLOPT_WRITEFUNCTION callback

2012-02-13 Thread Lars Nilsson
On Mon, Feb 13, 2012 at 7:39 AM, Daniel Stenberg wrote: > On Mon, 13 Feb 2012, Yehezkel Horowitz wrote: > >> Currently each easy handle has its own 2 buffers with fixed size of 16K. >> >> This enforces the application that uses libcurl to copy the data when the >> callbacks are called, since it wi

RE: Avoid copying data in CURLOPT_WRITEFUNCTION callback

2012-02-13 Thread Daniel Stenberg
On Mon, 13 Feb 2012, Yehezkel Horowitz wrote: Currently each easy handle has its own 2 buffers with fixed size of 16K. This enforces the application that uses libcurl to copy the data when the callbacks are called, since it will not be valid after the callback return. I understand perfectly.

RE: Avoid copying data in CURLOPT_WRITEFUNCTION callback

2012-02-13 Thread Yehezkel Horowitz
> Right, but the current fixed-size 32K (16+16) allocation could easily be converted into a more dynamic way that either would automatically grow according to some rule or it could be possible to set with an option. > A first and simple zero-copy implementation for libcurl would still have to p

RE: Invalid proxy settings

2012-02-13 Thread Daniel Stenberg
On Mon, 13 Feb 2012, Chandrakant Bagul -ERS, HCL Tech wrote: Yes, right. I was being stupid - setopt() basically only copies the string and does no parsing whatsoever. I could repeat your problem and I've now pushed a fix for this with an associated test case (1329). Thanks for reporting! Co

RE: Avoid copying data in CURLOPT_WRITEFUNCTION callback

2012-02-13 Thread Daniel Stenberg
On Mon, 13 Feb 2012, Yehezkel Horowitz wrote: if I would reconsider it, someone would have to show a significant performance boost with the use of something like that. Since such approach will require dynamic buffer allocation, I think this could improve the memory foot print as well. Today

Re: [PATCH] Enable multiple files in test scripts

2012-02-13 Thread Daniel Stenberg
On Sun, 12 Feb 2012, Colin Hogben wrote: When writing a test case, I discovered that the getpart() function in runtests.pl concatenates the content of all sections, whereas I would prefer to have several different files created (e.g. to verify multi-file upload). This concatenation 'feature'

RE: Invalid proxy settings

2012-02-13 Thread Chandrakant Bagul -ERS, HCL Tech
Hi Daniel, >Yes, right. I was being stupid - setopt() basically only copies the string and >does no parsing whatsoever. I could repeat your problem and I've now pushed a >fix for this with an associated test case (1329). Thanks for reporting! Thanks for consideration. Could you please explain th

RE: Avoid copying data in CURLOPT_WRITEFUNCTION callback

2012-02-13 Thread Yehezkel Horowitz
>> It was removed from the list a few months ago, presumably due to lack of >> interest. > Indeed. > if I would reconsider it, someone would have to show a significant > performance boost with the use of something like that. Since such approach will require dynamic buffer allocation, I think

Re: Avoid copying data in CURLOPT_WRITEFUNCTION callback

2012-02-13 Thread Daniel Stenberg
On Mon, 13 Feb 2012, Dan Fandrich wrote: It was removed from the list a few months ago, presumably due to lack of interest. Indeed. if I would reconsider it, someone would have to show a significant performance boost with the use of something like that. -- / daniel.haxx.se --

Re: Avoid copying data in CURLOPT_WRITEFUNCTION callback

2012-02-13 Thread Dan Fandrich
On Mon, Feb 13, 2012 at 10:36:04AM +0100, Konstantin Miller wrote: > Is there any way to avoid copying data between the buffer that is passed to > the > callback function, which is set with CURLOPT_WRITEFUNCTION, and my own buffer? > Can I tell libcurl that I would like to reuse its buffer and tha

Fwd: Multiple requests on Same CURL handle fails.

2012-02-13 Thread Prabu RM
-- Forwarded message -- From: Prabu RM Date: Mon, Feb 13, 2012 at 1:49 PM Subject: Multiple requests on Same CURL handle fails. To: curl-library@cool.haxx.se Hi, We used to transfer files to remote server using libcurl. All we know there are methods like *PUT,POST,GET,HEAD,DELET

Avoid copying data in CURLOPT_WRITEFUNCTION callback

2012-02-13 Thread Konstantin Miller
Hi! Is there any way to avoid copying data between the buffer that is passed to the callback function, which is set with CURLOPT_WRITEFUNCTION, and my own buffer? Can I tell libcurl that I would like to reuse its buffer and that I will free it myself later on? Or, even better, that I will give it

Multiple requests on Same CURL handle fails.

2012-02-13 Thread Prabu RM
Hi, We used to transfer files to remote server using libcurl. All we know there are methods like *PUT,POST,GET,HEAD,DELETE* in order to manipulate the transfer file. Here is one major issue we are facing on libcurl. *Issue:* Multiple request methods say HEAD & PUT in a single CURL reusing handle