curl-library
"Empty reply from server" with libCurl and Visual C++ 2008 on a Win32 Console Application
Date: Wed, 7 Jan 2009 15:03:58 -0600
I am getting the following error in my application:
Enter your stock: NASDAQ:AAPL
http://finance.google.com/finance/historical?q=NASDAQ:AAPL&output=csv
Retrieving http://http://finance.google.com/finance/historical?q=NASDAQ:AAPL&output=csv
* About to connect() to finance.google.com port 80 (#0)
* Trying 74.125.77.99... connected
* Connected to finance.google.com (74.125.77.99) port 80 (#0)
> POST /finance/historical?q=NASDAQ:AAPL&output=csv HTTP/1.1
User-Agent: curl/7.16.3 (i686-pc-cygwin) libcurl/7.16.3 OpenSSL/0.9.8h
zlib/1.2.3 libssh2/0.15-CVS
Host: finance.google.com
Accept: */*
Content-Length: 3
Content-Type: application/x-www-form-urlencoded
* Empty reply from server
* Connection #0 to host finance.google.com left intact
* Closing connection #0
Error: [52] - Empty reply from server
No file found.
Press any key to continue . . .
When using curl from the command line, I do the exact same thing but I get
the following:
$ curl -v -d url
"http://finance.google.com/finance/historical?q=NASDAQ:AAPL&output=csv"
* About to connect() to finance.google.com port 80 (#0)
* Trying 74.125.77.99... connected
* Connected to finance.google.com (74.125.77.99) port 80 (#0)
> POST /finance/historical?q=NASDAQ:AAPL&output=csv HTTP/1.1
> User-Agent: curl/7.16.3 (i686-pc-cygwin) libcurl/7.16.3 OpenSSL/0.9.8h zlib/1.2.3 libssh2/0.15-CVS
> Host: finance.google.com
> Accept: */*
> Content-Length: 3
> Content-Type: application/x-www-form-urlencoded
>
< HTTP/1.1 200 OK
< Date and the rest of the correct response
Regardless of whether I change the url or my settings, I always get "Error:
[52] - Empty reply from server", what gives?
Thanks,
Zach
Received on 2009-01-07