/* Credit: CZFree.Net,Martin Devera,Netdave,Aquarius,Gandalf */\r
/* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */\r
\r
-/* Modified by: xChaos, 20150331\r
+/* Modified by: xChaos, 20151020\r
ludva, 20080415\r
\r
Prometheus QoS is free software; you can redistribute it and/or\r
#include "cll1-0.6.2.h"\r
#include "ipstruct.h"\r
\r
-const char *version = "0.8.5-c";\r
+const char *version = "0.8.5-d";\r
\r
/* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */\r
-/* Versions: 0.8.3 is development release, 0.8.4 will be "stable" */\r
+/* Versions: 0.8.5 is development release, 0.8.6 will be "stable" */\r
/* Official Trac URL: https://dev.arachne.cz/svn/prometheus */\r
/* Official SVN URL: https://dev.arachne.cz/repos/prometheus */\r
/* BTC donations account: 19rriLx8vR19wGefPaMhakqnCYNYwjLvxq */\r
\r
if(ip->keyword->download_aggregation)\r
{\r
- if(min_mbps <= avg_mbps_down)\r
+ if(min_mbps/ip->keyword->download_aggregation <= avg_mbps_down)\r
{\r
unshape_this_ip = 0;\r
agreg = (int)((float)(avg_mbps_down+1)/min_mbps+.5);\r
ip->max /= agreg;\r
+ ip->pps_limit /= agreg;\r
printf("Download aggregation 1:%d for %s (min: %lu Mbps avg: %ld Mbps)\n", agreg, ip->name, min_mbps, avg_mbps_down);\r
}\r
else\r
}\r
else if(ip->keyword->upload_aggregation)\r
{\r
- if(min_mbps <= avg_mbps_up)\r
+ if(min_mbps/ip->keyword->upload_aggregation <= avg_mbps_up)\r
{\r
unshape_this_ip = 0;\r
agreg = (int)((float)(avg_mbps_up+1)/min_mbps+.5);\r