sys_poll_intr: fix timeout arithmetic
commitfb496563b051757632bc2cb9bee8d08a93d3c903
authorDaniel Kobras <d.kobras@science-computing.de>
Mon, 21 Jul 2014 08:47:53 +0000 (21 10:47 +0200)
committerKarolin Seeger <kseeger@samba.org>
Thu, 21 Aug 2014 14:55:17 +0000 (21 16:55 +0200)
tree14e0191d49c6b2c1ba987f428769eeb1a86b7cb8
parent60300459fe49a28bc151d9ae77c8fb1d388e25e1
sys_poll_intr: fix timeout arithmetic

Callers of sys_poll_intr() assume timeout to be in milliseconds like
poll(2) expects, but implementation used nanosecond units. Also make
sure timeout doesn't become infinite by mistake during time arithmetic.

Signed-off-by: Daniel Kobras <d.kobras@science-computing.de>
Reviewed-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Bug: https://bugzilla.samba.org/show_bug.cgi?id=10731

Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Tue Jul 22 00:12:24 CEST 2014 on sn-devel-104
lib/util/select.c