cURL / Mailing Lists / curl-users / Single Mail

curl-users

CURLOPT_MAX_RECV_SPEED_LARGE still not limiting bandwidth?

From: Mark Hindley <mark_at_hindley.org.uk>
Date: Tue, 29 Jan 2008 00:51:01 +0000

Hi,

I am the maintainer of the debian apt-cacher package. I have recently
changed apt-cacher to use curl via the perl bindings.

It has just been pointed out to me (http://bugs.debian.org/462523) that
setting CURLOPT_MAX_RECV_SPEED_LARGE is not causing the download
bandwidth to be limited. I am unsure whether this is a specific perl
binding problem or libcurl in general. There was a fix in this area a
while ago, (http://curl.haxx.se/bug/view.cgi?id=1603712), but I am using
7.17.1 which is more current. Linux system.

I am setting

 $curl->setopt(CURLOPT_MAX_RECV_SPEED_LARGE, $maxspeed);

where $maxspeed is an integer and then using the $curl handle later. Is
that correct?

Despite this, download rates are not limited. This is confirmed by
$curl->getinfo(CURLINFO_SPEED_DOWNLOAD).

Grateful for you help.

Mark
Received on 2008-01-29