*** Bug 55227 has been marked as a duplicate of this bug. ***
Created attachment 28662 [details] [diff] [review] Proxy settings UI and functionality, HTTP support added via libxpnet use (FTP still supported).
Created attachment 28663 [details] [diff] [review] Revised patch includes the Makefile.in changes as well now.
you're probably doing a whole lot more floating point math than you need to here: + diff_usecs = (aPost->tv_sec - aPre->tv_sec) * USECS_PER_SEC; + diff_usecs += (float)aPost->tv_usec - (float)aPre->tv_usec; + rate = ((float)(aBytes/KILOBYTE))/((float)(diff_usecs/USECS_PER_SEC)); if you think about it, you've got two integer constants in this last calculation. Simplified, this is: (aBytes/KILOBYTE) * (USECS_PER_SEC/diff_usecs) which is actually the same as (aBytes * USECS_PER_SEC) / (KILOBYTE * diff_usecs) which is actually the same as (aBytes/diff_usecs) / (USECS_PER_SEC / KILOBYTE) and if you think about it that way, the compiler can do the work of USECS_PER_SEC/KILOBYTE at compile time this could actually gain you some accuracy as well because your'e not dividing or multiplying by very large numbers.. I love numerical math. so if you switch to that, sr=alecf
Fix checked in.
*** Bug 79357 has been marked as a duplicate of this bug. ***