Welcome! Log In Create A New Profile

Advanced

[nginx] svn commit: r4962 - trunk/src/http

Anonymous User
December 12, 2012 09:50AM
Author: vbart
Date: 2012-12-12 14:48:48 +0000 (Wed, 12 Dec 2012)
New Revision: 4962
URL: http://trac.nginx.org/nginx/changeset/4962/nginx

Log:
Limit rate: fixed integer overflow in limit calculation (ticket #256).

Patch by Alexey Antropov.



Modified:
trunk/src/http/ngx_http_write_filter_module.c

Modified: trunk/src/http/ngx_http_write_filter_module.c
===================================================================
--- trunk/src/http/ngx_http_write_filter_module.c 2012-12-12 13:50:07 UTC (rev 4961)
+++ trunk/src/http/ngx_http_write_filter_module.c 2012-12-12 14:48:48 UTC (rev 4962)
@@ -207,7 +207,7 @@
}

if (r->limit_rate) {
- limit = r->limit_rate * (ngx_time() - r->start_sec + 1)
+ limit = (off_t) r->limit_rate * (ngx_time() - r->start_sec + 1)
- (c->sent - clcf->limit_rate_after);

if (limit <= 0) {

_______________________________________________
nginx-devel mailing list
nginx-devel@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx-devel
Subject Author Views Posted

[nginx] svn commit: r4962 - trunk/src/http

Anonymous User 1091 December 12, 2012 09:50AM



Sorry, you do not have permission to post/reply in this forum.

Online Users

Guests: 188
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready