]> git.ipfire.org Git - thirdparty/valgrind.git/commit
vgdb: Handle EAGAIN in read_buf
authorMark Wielaard <mark@klomp.org>
Thu, 20 Apr 2023 10:59:02 +0000 (12:59 +0200)
committerMark Wielaard <mark@klomp.org>
Thu, 20 Apr 2023 11:00:49 +0000 (13:00 +0200)
commit0ead4c39f0268420f24df64629d80bd45614fe04
treecf1365e501522c460f26f068e7d34c14d9c71d16
parent6effd73e9071efde14cf55c6b04c1217cc4c8515
vgdb: Handle EAGAIN in read_buf

The file descriptor is on non-blocking mode and read_buf should only
be called when poll gave us an POLLIN event signaling the file
descriptor is ready for reading from. Still sometimes we do get an
occasional EAGAIN. Just do as told in that case and try to read again.

Also fix an ERROR errno in getpkt. This has never been observed, but
not getting the actual errno if the write fails in that case would be
really confusing.
coregrind/vgdb.c