mtr/mtr-0.71-underflow.patch
Marcela Mašláňová 22da837052 - /* impossible? if( totusec < 0 ) totusec = 0 */;
-
/* sometimes < 0 */
totusec = abs(totusec);
2006-05-30 08:47:56 +00:00

15 lines
503 B
Diff

--- mtr-0.71/net.c.fix 2006-03-24 07:37:17.000000000 +0100
+++ mtr-0.71/net.c 2006-05-30 08:52:50.000000000 +0200
@@ -354,8 +354,9 @@
totusec = (now.tv_sec - sequence[seq].time.tv_sec ) * 1000000 +
(now.tv_usec - sequence[seq].time.tv_usec);
- /* impossible? if( totusec < 0 ) totusec = 0 */;
-
+ /* sometimes < 0 */
+ totusec = abs(totusec);
+
if ( addrcmp( (void *) &(host[index].addr),
(void *) &unspec_addr, af ) == 0 ) {
// should be out of if as addr can change