Req #54622 [NEW]: cURL speed limit options not implemented till present day.

From: Date: Thu, 28 Apr 2011 14:13:34 +0000
Subject: Req #54622 [NEW]: cURL speed limit options not implemented till present day.
Groups: php.bugs 
Request: Send a blank email to php-bugs+get-160413@lists.php.net to get a copy of this message
From:             
Operating system: Linux (Gentoo)
PHP version:      5.3.6
Package:          cURL related
Bug Type:         Feature/Change Request
Bug description:cURL speed limit options not implemented till present day.

Description:
------------
This request related to bug for previous version of PHP 
(http://bugs.php.net/bug.php?id=51815), but as i found i have same issue on
php 
5.3.6.
Libcurl have  options as CURLOPT_MAX_RECV_SPEED_LARGE and 
CURLOPT_MAX_SEND_SPEED_LARGE, but seems them didn't work at current stable

version. to reproduce the problem i use same script as in previous bug
report.
 

Test script:
---------------
<?php

// create a new cURL resource
$ch = curl_init();

$fh = fopen("out.dat", "w");

// set URL and other appropriate options
curl_setopt($ch, CURLOPT_MAX_RECV_SPEED_LARGE, 10240);
curl_setopt($ch, CURLOPT_URL,
"http://bitcast-a.bitgravity.com/bitgravity/1MB");
curl_setopt($ch, CURLOPT_FILE, $fh);
curl_setopt($ch, CURLOPT_HEADER, 0);

// grab URL
curl_exec($ch);

// close cURL resource, and free up system resources
curl_close($ch);
fclose($fh);
?>


Expected result:
----------------
Script should download the link with approximate speed as 10kb/s and took
around 
seconds...

Actual result:
--------------
Script download file with full speed which available for my connection,
i.e. no 
any rate limit was assigned to curl task.  

-- 
Edit bug report at http://bugs.php.net/bug.php?id=54622&edit=1
-- 
Try a snapshot (PHP 5.2):            http://bugs.php.net/fix.php?id=54622&r=trysnapshot52
Try a snapshot (PHP 5.3):            http://bugs.php.net/fix.php?id=54622&r=trysnapshot53
Try a snapshot (trunk):              http://bugs.php.net/fix.php?id=54622&r=trysnapshottrunk
Fixed in SVN:                        http://bugs.php.net/fix.php?id=54622&r=fixed
Fixed in SVN and need be documented: http://bugs.php.net/fix.php?id=54622&r=needdocs
Fixed in release:                    http://bugs.php.net/fix.php?id=54622&r=alreadyfixed
Need backtrace:                      http://bugs.php.net/fix.php?id=54622&r=needtrace
Need Reproduce Script:               http://bugs.php.net/fix.php?id=54622&r=needscript
Try newer version:                   http://bugs.php.net/fix.php?id=54622&r=oldversion
Not developer issue:                 http://bugs.php.net/fix.php?id=54622&r=support
Expected behavior:                   http://bugs.php.net/fix.php?id=54622&r=notwrong
Not enough info:                     http://bugs.php.net/fix.php?id=54622&r=notenoughinfo
Submitted twice:                     http://bugs.php.net/fix.php?id=54622&r=submittedtwice
register_globals:                    http://bugs.php.net/fix.php?id=54622&r=globals
PHP 4 support discontinued:          http://bugs.php.net/fix.php?id=54622&r=php4
Daylight Savings:                    http://bugs.php.net/fix.php?id=54622&r=dst
IIS Stability:                       http://bugs.php.net/fix.php?id=54622&r=isapi
Install GNU Sed:                     http://bugs.php.net/fix.php?id=54622&r=gnused
Floating point limitations:          http://bugs.php.net/fix.php?id=54622&r=float
No Zend Extensions:                  http://bugs.php.net/fix.php?id=54622&r=nozend
MySQL Configuration Error:           http://bugs.php.net/fix.php?id=54622&r=mysqlcfg



Thread (5 messages)

« previous php.bugs (#160413) next »