Hey Burt,
LOL it sounds like they really are being odd about things and not trusting
your judgement like they ought to.. :P
Anyways, your questions regarding the multi interface...
You can actually use the fd stuff w/ the multi interface as well (have you
seen this page? http://curl.haxx.se/libc
Thanks Daniel!
On Fri, Jan 27, 2012 at 1:23 PM, Daniel Stenberg wrote:
> On Fri, 27 Jan 2012, Alan Wolfe wrote:
>
> But, I personally use curl_multi_info_read
>> http://curl.haxx.se/libcurl/c/**curl_multi_info_read.html<http://curl.haxx.se/libcurl/c/curl_multi_info_re
i just did this the other day and sorry i am just running out the door but
if i recall correctly, there was a "library" directory that contained the
project for just libcurl.
I was able to build the lib and dlls from that (both flavors worked)
the instructions on how to build libcurl on windows f
I think it is possible actually!
Libcurl supports telnet, which is essentially what you want.
I dont have any info on hand but try google or the libcurl site and see if
you can find some more info about how to do telnet with libcurl
On Wed, Feb 22, 2012 at 8:08 PM, Gaylord Yu wrote:
> I have i
i never use fd set when using the multi interface (but your mileage may
require variance!)
I just always call multi preform each frame and read the messages to know
when something has finished.
When going this route, the code is more of a "busy wait" loop instead of a
nice "sleep until there is d
In case you dont get a better response, have you thought about putting both
those items into one peice of XML?
I mean for instance this:
foosomething
On Fri, Apr 6, 2012 at 7:21 PM, Rajesh Khan wrote:
> The following cul command works when i am passing a single XML object
> curl -X PUT -HConte
specifically...
size is the size of one data item, nmemb is the number of data items.
all you really need to worry about is (size * nmemb)
That's how many bytes total there are.
Hope that helps!
On Sat, Apr 28, 2012 at 7:10 PM, Jim Lloyd wrote:
> Yes. The function signature is the same signat
Playing devil's advocate... well engineered code makes it harder, or
impossible to do the wrong thing, by accident or on purpose.
For instance, well named enums and enum values instead of "magic numbers"
are always better for function parameters.
That being said... I use libcurl quite a bit and l
Would it be possible to have the function take an enum instead of an int on
top of whatever other solution you guys use?
Its really telling watching this conversation how useful it would be.
You guys are talking about 0, 1 and 2 which is completely meaningless
without reading documentation or sou
Actually i think i know what your issue is. Curl is single threaded, even
if you use the multi interface. If you are doing a bunch of work in the
callback function, that means that the main thread (the only thread) is
doing that, and not processing data waiting on the line etc.
Also, usually it'
No idea on this issue specifically (sorry), but a handy little tip...
if you ever want to defeat caching (like as a temporary work
around...) you can append a random number onto the end of a URL and
that basically defeats every single caching mechanism there is.
For instance instead of:
http://myu
I expect in 15 years the topic will be "30 years - from FTP to FTL"
Thanks for making such a great library Daniel!
On Mar 20, 2013 7:44 AM, "Daniel Stenberg" wrote:
> Hi friends,
>
> At this day, 15 years ago, I uploaded the first release of curl to the
> world.
>
> I had played around with diff
It's a common scapegoat for mysterious problems, but have you
considered that this might be a memory stomping problem?
Something else corrupting memory causing select to malfunction.
If you have a minimal program that is making this problem appear, you
might check your data callback to make sure
A dumb question, but just in case... did you build or download a
windows libcurl binaries that have SSL enabled?
There are licensing issues around SSL support so some windows binaries
you can download don't have SSL enabled.
On Mon, May 13, 2013 at 1:13 PM, Thomas Mayer wrote:
> Hello,
>
> I am
You ought to google web sockets.
Basically, with web sockets you have the initial overhead of an http
request and response, but then the connection doesn't close and you can
send and receive data (true bidirectional communication) all day long
without the overhead of http.
One of the benefits of
Hey Guys,
I'm looking to compile libcurl on a platform that doesnt seem to be
currently supported (xbox 360)
I was wondering, where would someone start with the "port" to a new platform?
Is there a specific file that has the os specific functionality? I
noticed the os-specific.c / .h but that d
Thu, Aug 19, 2010 at 11:20 AM, Daniel Stenberg wrote:
> On Thu, 19 Aug 2010, Alan Wolfe wrote:
>
>> I'm looking to compile libcurl on a platform that doesnt seem to be
>> currently supported (xbox 360)
>
> Isn't that running something similar to win32?
>
>&
Another question for you guys...
I've noticed that some binaries have SSL support and others don't.
I know there is some kind of legal or licensing issue associated with
using SSL with libcurl but never really quite understood what it was.
I was looking at this page but it didnt really clear it
Heya!
Compiling libcurl in windows for me was amazingly easy.
I just downloaded the source and there was a dsw file.
I opened it and MSVC said it was old and needed to be converted and i said ok.
After that i just selected what flavor (Debug or Release and Static or
Dynamic) and it compiled str
Do you think you could be seeing a cached response?
On Sep 20, 2010 8:27 AM, "Johnny Beardsmore" wrote:
Hi,
I'm using the following (abreviated) code:
//**
curl_easy_reset(curl);
curl_wr_error = curl_wr_index = 0;
// setup curl options
curl_eas
pe that helps, someone else may have some more insight too.
On Mon, Sep 20, 2010 at 8:30 AM, Alan Wolfe wrote:
> Do you think you could be seeing a cached response?
>
> On Sep 20, 2010 8:27 AM, "Johnny Beardsmore" wrote:
>
&g
I was thinking of caching happening at the OS level. Is that a possibility?
On Mon, Sep 20, 2010 at 9:31 AM, Daniel Stenberg wrote:
> On Mon, 20 Sep 2010, Alan Wolfe wrote:
>
>> To expand on that, i'm thinking if you are making a request with the same
>> URL after di
Lock as in your computer freezes up and never comes back?
Michael you are not really giving very good info and your attitude is
bordering on belligerent...
I apologize if english isn't your main language, i know that can cause
communication issues :P
On Wed, Dec 8, 2010 at 2:46 PM, Michael Meneg
"Can't I do some timout ? e.g. libcurl will return after 60 seconds or so
whether it did or did not get the data ?"
you can if you are using the multi interface.
The multi interface lets you make requests that happen in the background and
so if it takes too long you can just go on with your life
Hey Guys,
I was wondering, what is the proper way to initialize ssl?
Is it by passing the right flag to curl_global_init or are there other ways
too?
Thanks!
---
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette:
No problems here.
BTW i have used your lib for so much awesome stuff.
Over the last couple years I've been using it to do content sharing / stat
reporting from within video games.
libcurl talking to a LAMP server = easy mode (but for some reason other game
developers look at the results and thin
Thanks Daniel!
On Fri, Jan 14, 2011 at 2:54 AM, Daniel Stenberg wrote:
> On Thu, 13 Jan 2011, Alan Wolfe wrote:
>
> I was wondering, what is the proper way to initialize ssl?
>>
>> Is it by passing the right flag to curl_global_init or are there other
>> ways too?
I agree the "CURLE_OUT_OF_MEMORY" is pretty misleading.
I hit this problem last week and had to step through the source to see what
the problem was.
On Tue, Jan 18, 2011 at 7:39 AM, Bjoern Sikora
wrote:
> Hi folks,
>
> attached a simple patch to get the real OpenSSL errcode if SSL context
> crea
Heya,
http://curl.haxx.se/libcurl/c/example.html
I googled "libcurl FTP tutorial" and it was the 2nd result.
The first result might also be of interest to you but ::shrug:: this link
has the example code you were looking for.
On Thu, Feb 3, 2011 at 6:12 AM, goeie spullen wrote:
> Hi, Let me in
What compiler are you using?
Using microsoft visual studio i dont get the errors you are, it compiles
just fine as C++ for me.
On Thu, Feb 3, 2011 at 2:28 PM, Prashant R wrote:
> I know that this library was intended to compile in C however I have
> certain limitations where this needs to be co
Hey Guys,
I'm using the libcurl multi interface on windows and was wondering, how does
it work under the hood?
Specifically I was wondering, does it run requests on another thread or does
it just use a small time slice each frame?
I'm noticing something in my application where if i have a tight
ut not sure how much, or how
that amount of time might vary from system to system.
On Fri, Feb 4, 2011 at 11:55 AM, Alan Wolfe wrote:
> Hey Guys,
>
> I'm using the libcurl multi interface on windows and was wondering, how
> does it work under the hood?
>
> Specifically I
unch!
On Fri, Feb 4, 2011 at 2:03 PM, Dan Fandrich wrote:
> On Fri, Feb 04, 2011 at 01:29:28PM -0800, Alan Wolfe wrote:
> > Quick update... i notice that if i tick the multi interface 20 times per
> frame
> > instead of just once, i get response time back down to the 2-3 second
&g
ld be going on?
On Fri, Feb 4, 2011 at 2:40 PM, Alan Wolfe wrote:
> i'm doing a select before the curl_multi_perform with a small timeout (10
> usec's)
>
> Now of course it seems obvious what the problem is hehe... i probably
> should be using more than 10usec's if
Awesome, that's probably what's going wrong then. I can't wait to give that
a try.
Thanks a ton!
On Sun, Feb 6, 2011 at 2:18 PM, Daniel Stenberg wrote:
> On Fri, 4 Feb 2011, Alan Wolfe wrote:
>
> so i do have a select before my curl_multi_perform with a timeout of
>
Heya,
the malloc(1) isn't being stingy. As the comments say, it will be
resized with realloc calls later on.
Basically, it allocates a single byte so there's a valid memory
address in chunk.memory so that realloc can be called on it later on.
If it started out NULL, there would have to be an if
Hey there again.
curel_easy_perform will block until the request is finished, so there
is no danger of your callback getting called after the free.
If ever you don't want to block your program execution while a request
happens, you can check out the multi interface.
>From what it sounds like, bl
oh and what i mean by saying that curl_easy_perform "blocks" is just
that, by the time curl_easy_perform is done and your code moves to the
next statement, your request will be finished, all your callbacks will
have been called, etc.
On Sun, Feb 27, 2011 at 10:30 PM, Alan Wolfe wr
Doesn't this make you wish that C/C++ could more easily enforce type
safety between different enums??
I wonder how much dev time has been lost in the world because someone
was mistakenly comparing 2 different enums together.
On Mon, Mar 7, 2011 at 2:31 PM, Daniel Stenberg wrote:
> On Mon, 7 Mar
Yep...
To reinforce what our fearless leader Daniel said, comet as i
understand it (and have implemented it in the past in ajax type
situations) is just the server delaying the response for a time if no
data is currently available so that the client and server can have
more "real time" type commun
Not sure if this will solve your issue but are you aware of the multi interface?
On Sun, Mar 20, 2011 at 12:23 PM, ajil koshy wrote:
> Hi,
>
> I have just started using libcurl library. I had a question about how we can
> implement full duplex communication using libcurl library. I have writting
Yeah i second that!
Daniel, w/o libcurl i have no idea what us folks trying to do HTTP
from c++ would do (not to mention the other uses). The world would be
a much darker place.
On Sun, Mar 20, 2011 at 3:11 PM, Lou Picciano wrote:
> Daniel,
> Happy Anniversary! Even 'Happy Birthday', dare I say
16 bits?? thats tiny you sure about that?
fwiw size_t is 64 bits on my machine
On Sat, Mar 26, 2011 at 6:37 PM, wrote:
> Hi everyone,
>
> My write callback function looks like this:
>
> size_t writehttpcallback ( void *ptr, size_t size, size_t nmemb, void *data)
> {
> size_t realsize = siz
Hey Guys,
I was wondering... is the multi interface multithreaded behind the
scenes at all or does it all work on a single thread?
Thank you!!
Alan
---
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://cur
Daniel <3
(:
On Fri, Apr 8, 2011 at 2:17 PM, Daniel Stenberg wrote:
> On Fri, 8 Apr 2011, Alan Wolfe wrote:
>
>> I was wondering... is the multi interface multithreaded behind the scenes
>> at all or does it all work on a single thread?
>
> It a
it sounds like you are getting utf8 encoded characters probably.
google how to convert from utf8 characters to wide characters (i think
there's a simple way to do it with std::string's) and i bet that'll
give you what you want
On Mon, Apr 25, 2011 at 6:42 AM, darekg11 wrote:
> Hi, I have sent ma
Essentially you have to look at how the site itself sends the username
and password in the http request, and then mimic that http request
with libcurl.
libcurl does HTTP but it doesn't parse html or fill out web forms.
On Tue, May 3, 2011 at 10:49 AM, darekg11 wrote:
> Hi, how can I send passwor
there may be some trickery in the download dialog - like it uses
javascript to fire off the download.
if so, you need to figure out what the final URL of the file you are
actually getting is, and do a curl request to that file location.
(View the page source to figure out what's going on)
they ma
it'll truncate the uploaded file yeah, but thats what Saqib is lookin for :P
the local file that you are uploading will be untouched.
you are just lying and telling curl you reached the end of file via
the callback return, you aren't actually altering the source file.
On Mon, May 9, 2011 at 11:1
the still_running int will drop to 0 when the request is complete.
just have a loop something like this...
while(still_running > 0)
{
Sleep(50); //yield the processor
//dont forget to pump libcurl in this loop (i forget the function name)
}
or of course, you can do work inside the while loop
determine when the request is completely transferred.
>
> Thanks
>
>
> On 5/20/11, Alan Wolfe wrote:
>> the still_running int will drop to 0 when the request is complete.
>>
>> just have a loop something like this...
>>
>> while(still_running > 0)
>
There has to be something crazy going on because if i'm reading this
correctly... if what you said is how it worked for everyone else (i
know it isn't how it works for me, or how the docs say it should
work), there would be some really BIG problems with using libcurl :P
your 3.07e+9 value sounds f
If what you are saying is what it's really doing, and no one else suggests
anything, you might also try going multithreaded.
Libcurl is thread safe with a few caveats (check out this page for more info
http://curl.haxx.se/libcurl/features.html)
On Mon, Jun 6, 2011 at 11:30 AM, Jimish Shah wrote:
Just to toss my 2 cents in I hit this sort of problem a couple months ago,
where the multi interface took way longer than it should have to get the
results.
The problem if i recall correctly was that i was using too small of a
timeout in my select() but i could be mistaken.
On Sat, Jun 11, 2011 a
Out of curiosity Paolo could you elaborate on the nature of the bug? was it
that select() wasn't getting enough time or something?
Thanks man (:
On Mon, Jun 13, 2011 at 2:34 PM, Paolo Piacentini wrote:
> I want to report that I discovered a BUG in my code.
>
> Everything is now back to normal
On Jul 20, 2011 11:28 PM, "Sumukh Anantha Manohar"
wrote:
Hi,
I am trying to download files whose size is greater than 2GB using curl
API's like curl_easy_perform ( ) and curl_easy_setopt ( ) on linux and unix
platforms using c++ language.
The problem is, the above functions are helping me to do
also hey you might want to profile things to see where your bottle necks are
before attempting a solution.
like for instance, if your hard drive is the slow part, and it's 100%
utilized, adding more threads isnt going to make the read head move any
faster.
just being able to see if it's CPU, stor
Unfortunately all you can really do is buffer more up before beginning
playback. If its latency issues and not connection speed that's the
problem, buffering should fix it nicely (:
On Aug 17, 2011 10:32 PM, "Konrad Scorciapino" wrote:
Hi there!
My music player uses libcurl to play shoutcast
I dont know what i was thinking, please listen to Daniel and ignore my
comment :P
Like he says, if it's just latency that is the problem, you shouldn't have
any issues once the data starts coming.
If the problem is that you don't have enough bandwidth, you need to either
buffer more up before sta
Is it a divide by zero crash? Look what happens in your code when utotal is
0.
On Sep 13, 2011 1:06 AM, "Oleksiy" wrote:
int ProgressShow(int (*fun)(double data), double dltotal, double dlnow,
double ultotal, double ulnow)
{
printf("%f / %f (%g %%)\n", ulnow, ultotal, ulnow*100.0/ultotal);
only a partial answer but have you seen this page?
http://curl.haxx.se/libcurl/features.html
libcurl is designed and implemented entirely thread safe. There are some
considerations to keep in mind when using libcurl in multiple threads
though, as mentioned below:
*Never* share libcurl handles be
DANIEL HELP I HAVE A QUESTION
Teasing! Have a good one man.
On Thu, Oct 6, 2011 at 5:09 PM, William Betts wrote:
> On Thu, Oct 6, 2011 at 10:03 AM, Daniel Stenberg wrote:
>
>> Hey friends,
>>
>> I'm off on vacation for a week starting tomorrow. Have patience, take an
>> extra beer and I'll be
Without seeing the code, 2 things come to mind
#1 - Does your program block at all on disk i/o (are you reading or writing
to the disk?) if so that could be bottlenecking your D/L.
#2 - Are you sure the problem is on your end, not the server side?
If you show us your code we can probably help a l
curl_easy_perform(curl);
> stop = clock();
> curl_easy_cleanup(curl); }
>
> cout << "Download speed: " << page.byteArray().getSize() * 1000 /
> ((stop - start) * 1024) << " KB/s\n";
> }
> The code still looks p
Maybe give this a shot... the command line curl has an option that makes it
spit out c code that you can compile with libcurl. You could do that and
see if you get better performance.
If so, you can try changing things til it goes slow again, or just use that
code as a basis for your code
>From
not sure if it will help, but your program and libcurl need to match for
some compilation settings.
#1 - you need to use the same CLR (runtime). If you use "multithreaded
debug dll" in your program, but libcurl is compiled with "multithreaded
debug" for instance, that will cause problems.
#2 - m
Im glad it works! You probably want to get the release flavors matching and
use that instead of the debug. You should even be able to link to the
release libs from your debug exe i believe.
If you use debug versions of the libraries (and your code), it will run
slower, although maybe not in any
Hey Dan,
FYI he ran curl with --libcurl so that it created some source code to use
with libcurl to do the same request.
With that code unmodified and his libraries he built, he got the slow
transfer rate he saw before.
With the curl command line utility he gets about 10x as much speed.
On Tue,
Thats actually a really good point. Maybe libcurl is displaying kilo BITS
per second, and you are calculating kilo BYTES per second.
Bandwidth is often expressed in Kb, not KB and aprox 30-40KB/sec == aprox.
300Kb/sec which fits with your numbers!
On Tue, Oct 11, 2011 at 1:28 PM, Vladimir Grishc
and just to make sure... are you building the release version of libcurl,
and have rtti and exceptions turned off, optimizations turned on (on by
default in release) and no crazy options turned on such as GS (stack
checking)
On Wed, Oct 12, 2011 at 1:07 AM, Guenter wrote:
> Am 11.10.2011 22:13,
Check out this page Suneepa, particularly "Anatomy of a Soap Request".
http://www.ibm.com/developerworks/webservices/library/ws-peer3/index.html
That shows examples with java, which you can follow, or just ignore. Once
you understand how SOAP works at it's core, it should be trivial to
implement
Hi there. That stuff you are seeing is the contents of the png file, like
you would see if you looked at the png file in text editor.
I believe the solution is that you need to set your http headers to
appropriate values to display an image.
Try putting this line at the very top of your php:
He
72 matches
Mail list logo