diff options
author | khng300 <[email protected]> | 2020-10-12 15:44:22 +0800 |
---|---|---|
committer | GitHub <[email protected]> | 2020-10-12 09:44:22 +0200 |
commit | 7c9a666c8c60deb3747b486a6737ed7727dd4579 (patch) | |
tree | 328464ce57a8464704eec9fab0a285286a51dba7 /src | |
parent | 226d383c136b8586b69b74f420a5afc8b243cf49 (diff) | |
download | cubeb-7c9a666c8c60deb3747b486a6737ed7727dd4579.tar.gz cubeb-7c9a666c8c60deb3747b486a6737ed7727dd4579.zip |
oss: Initialize cubeb_stream::state properly (#618)
Diffstat (limited to 'src')
-rw-r--r-- | src/cubeb_oss.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/cubeb_oss.c b/src/cubeb_oss.c index a95a4dd..6376889 100644 --- a/src/cubeb_oss.c +++ b/src/cubeb_oss.c @@ -119,7 +119,7 @@ struct cubeb_stream { bool thread_created; /* (m) */ bool running; /* (m) */ bool destroying; /* (m) */ - cubeb_state state; + cubeb_state state; /* (m) */ float volume /* (m) */; struct oss_stream play; struct oss_stream record; @@ -1007,6 +1007,7 @@ oss_stream_init(cubeb * context, ret = CUBEB_ERROR; goto error; } + s->state = CUBEB_STATE_STOPPED; s->record.fd = s->play.fd = -1; s->nfr = latency_frames; if (input_device != NULL) { |