Public bug reported:
Binary package hint: iputils-ping
1). Ubunto 9.10
2). iputils-ping 3:20071127-1build1
3). Arping to send packets
4). Setting the -w flag to greater than 19737417 will cause the programme to
finish and not send any packets
In the arping.c file there are multiple lines commented out mainly
includes with no explination as to why, however one line commented out
is the definition of a function which is later referenced and causes the
programme to finish early.
---------------------------------------------------------------
This is the function that is commented out:
#
#define MS_TDIFF(tv1,tv2) ( ((tv1).tv_sec-(tv2).tv_sec)*1000 + \
#
((tv1).tv_usec-(tv2).tv_usec)/1000 )
--------------------------------------------------------------
This is the point where the code is refenced.:
void catcher(void)
{
struct timeval tv;
gettimeofday(&tv, NULL);
if (start.tv_sec==0)
start = tv;
if (count-- == 0 || (timeout && MS_TDIFF(tv,start) > timeout*1000 +
500))
finish();
if (last.tv_sec==0 || MS_TDIFF(tv,last) > 500) {
send_pack(s, src, dst, &me, &he);
if (count == 0 && unsolicited)
finish();
}
alarm(1);
}
-------------------------------------------
This is a work around fix:
void catcher(void)
{
struct timeval tv;
gettimeofday(&tv, NULL);
if (start.tv_sec==0)
start = tv;
if (count-- == 0 )
finish();
if (last.tv_sec==0) {
send_pack(s, src, dst, &me, &he);
if (count == 0 && unsolicited)
finish();
}
alarm(1);
}
5). the fix above allows a the user to set a -w flag of 19737418 and
above and still send packets.
ProblemType: Bug
Architecture: i386
Date: Tue Nov 17 15:26:04 2009
DistroRelease: Ubuntu 9.10
InstallationMedia: Ubuntu 9.10 "Karmic Koala" - Release i386 (20091028.5)
Package: iputils-ping 3:20071127-1build1
ProcEnviron:
PATH=(custom, no user)
LANG=en_US.UTF-8
SHELL=/bin/bash
ProcVersionSignature: Ubuntu 2.6.31-14.48-generic
SourcePackage: iputils
Uname: Linux 2.6.31-14-generic i686
** Affects: iputils (Ubuntu)
Importance: Undecided
Status: New
** Tags: apport-bug i386
--
Commented out code in arping.c causes issues when using large numbers with the
-w flag
https://bugs.launchpad.net/bugs/484242
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
--
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs