Skip to content
This repository was archived by the owner on Feb 23, 2026. It is now read-only.

Commit 45cd8e8

Browse files
committed
pymavlink: prevent long sleeps on connections with no fd
1 parent d89a2c1 commit 45cd8e8

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

pymavlink/mavutil.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -206,7 +206,7 @@ def write(self, buf):
206206
def select(self, timeout):
207207
'''wait for up to timeout seconds for more data'''
208208
if self.fd is None:
209-
time.sleep(timeout)
209+
time.sleep(min(timeout,0.5))
210210
return True
211211
try:
212212
(rin, win, xin) = select.select([self.fd], [], [], timeout)

0 commit comments

Comments
 (0)