mode cannot be 0 Coverity ID: #1137964 Signed-off-by: Peter Meerwald-Stadler <pmeerw at pmeerw.net> --- src/modules/oss/module-oss.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/modules/oss/module-oss.c b/src/modules/oss/module-oss.c index 8a5a692..5ad765d 100644 --- a/src/modules/oss/module-oss.c +++ b/src/modules/oss/module-oss.c @@ -1195,7 +1195,7 @@ int pa__init(pa_module*m) { goto fail; } - mode = (playback && record) ? O_RDWR : (playback ? O_WRONLY : (record ? O_RDONLY : 0)); + mode = (playback && record) ? O_RDWR : (playback ? O_WRONLY : O_RDONLY); ss = m->core->default_sample_spec; map = m->core->default_channel_map; -- 2.7.4