diff options
Diffstat (limited to 'sound/core/pcm_misc.c')
-rw-r--r-- | sound/core/pcm_misc.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sound/core/pcm_misc.c b/sound/core/pcm_misc.c index c4eb561d2008..0956be39b035 100644 --- a/sound/core/pcm_misc.c +++ b/sound/core/pcm_misc.c @@ -423,7 +423,7 @@ int snd_pcm_format_set_silence(snd_pcm_format_t format, void *data, unsigned int return 0; width = pcm_formats[(INT)format].phys; /* physical width */ pat = pcm_formats[(INT)format].silence; - if (! width) + if (!width || !pat) return -EINVAL; /* signed or 1 byte data */ if (pcm_formats[(INT)format].signd == 1 || width <= 8) { |