mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-02-06 22:10:25 +01:00
*** empty log message ***
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@1312 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
This commit is contained in:
parent
a8b7e75e7a
commit
4cc7af6ef6
1 changed files with 4 additions and 2 deletions
|
|
@ -281,9 +281,11 @@ gboolean get_autoip (NMDevice *dev, struct in_addr *out_ip)
|
|||
}
|
||||
else
|
||||
{
|
||||
/* FIXME: we need to randomize the timeout _between_ MIN and MAX */
|
||||
unsigned int usecs_to_sleep = ((PROBE_MAX - PROBE_MIN) * 1000000) - 1;
|
||||
|
||||
/* We want to sleep between PROBE_MIN and PROBE_MAX seconds, exclusive */
|
||||
timeout.tv_sec += PROBE_MIN;
|
||||
timeout.tv_usec += (random () % 200000);
|
||||
timeout.tv_usec += 1 + (random () % usecs_to_sleep);
|
||||
}
|
||||
}
|
||||
else if (nannounce < ANNOUNCE_NUM)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue