mirror of
https://git.rwth-aachen.de/acs/public/villas/node/
synced 2025-03-09 00:00:00 +01:00
io: bugfix in state machine
This commit is contained in:
parent
66e3f6f45d
commit
9e97e22d10
1 changed files with 2 additions and 2 deletions
|
@ -505,14 +505,14 @@ FILE * io_stream_input(struct io *io) {
|
|||
|
||||
int io_sscan(struct io *io, const char *buf, size_t len, size_t *rbytes, struct sample *smps[], unsigned cnt)
|
||||
{
|
||||
assert(io->state == State::CHECKED || io->state == State::OPENED);
|
||||
assert(io->state == State::CHECKED || io->state == State::INITIALIZED || io->state == State::OPENED);
|
||||
|
||||
return io_type(io)->sscan ? io_type(io)->sscan(io, buf, len, rbytes, smps, cnt) : -1;
|
||||
}
|
||||
|
||||
int io_sprint(struct io *io, char *buf, size_t len, size_t *wbytes, struct sample *smps[], unsigned cnt)
|
||||
{
|
||||
assert(io->state == State::CHECKED || io->state == State::OPENED);
|
||||
assert(io->state == State::CHECKED || io->state == State::INITIALIZED || io->state == State::OPENED);
|
||||
|
||||
return io_type(io)->sprint ? io_type(io)->sprint(io, buf, len, wbytes, smps, cnt) : -1;
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue