Fixed handle_events

This commit is contained in:
Abramo Bagnara 2001-02-11 17:46:03 +00:00
parent 8afd6e69af
commit 955b9fc335
4 changed files with 11 additions and 5 deletions

View file

@ -220,7 +220,7 @@ static int snd_ctl_hw_read(snd_ctl_t *handle, snd_ctl_event_t *event)
snd_ctl_hw_t *hw = handle->private_data;
ssize_t res = read(hw->fd, event, sizeof(*event));
if (res <= 0)
return res;
return -errno;
assert(res == sizeof(*event));
return 1;
}