monitor: Drop monitor_fdset_dup_fd_find/_remove()

Those functions are not needed, one remove function should already
work.  Clean it up.

Here the code doesn't really care about whether we need to keep that dupfd
around if close() failed: when that happens something got very wrong,
keeping the dup_fd around the fdsets may not help that situation so far.

Cc: Dr. David Alan Gilbert <dave@treblig.org>
Cc: Markus Armbruster <armbru@redhat.com>
Cc: Philippe Mathieu-Daudé <philmd@linaro.org>
Cc: Paolo Bonzini <pbonzini@redhat.com>
Cc: Daniel P. Berrangé <berrange@redhat.com>
Signed-off-by: Peter Xu <peterx@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
[add missing return statement, removal during traversal is not safe]
Signed-off-by: Fabiano Rosas <farosas@suse.de>
This commit is contained in:
Peter Xu 2024-06-17 15:57:20 -03:00 committed by Fabiano Rosas
parent 926554c0bf
commit 1cd93fb0bf
4 changed files with 7 additions and 42 deletions

View file

@ -9,11 +9,6 @@ int monitor_fdset_dup_fd_add(int64_t fdset_id, int flags)
return -1;
}
int64_t monitor_fdset_dup_fd_find(int dup_fd)
{
return -1;
}
void monitor_fdset_dup_fd_remove(int dupfd)
{
}