]> git.alsa-project.org Git - alsa-lib.git/commitdiff
pcm: add a note about return values of snd_pcm_state()
authorHenrik Enquist <henrik.enquist@gmail.com>
Wed, 7 Jul 2021 19:10:16 +0000 (21:10 +0200)
committerJaroslav Kysela <perex@perex.cz>
Fri, 3 Sep 2021 06:41:40 +0000 (08:41 +0200)
Fixes: https://github.com/alsa-project/alsa-lib/pull/162
Signed-off-by: Henrik Enquist <henrik.enquist@gmail.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
src/pcm/pcm.c

index 892abf98a734d4ea59a672212b7c6da986c03f42..9aec52d104506632fce4fe5a6915bcb25479af6d 100644 (file)
@@ -1059,6 +1059,10 @@ int snd_pcm_status(snd_pcm_t *pcm, snd_pcm_status_t *status)
  * This is a faster way to obtain only the PCM state without calling
  * \link ::snd_pcm_status() \endlink.
  *
+ * Note that this function always returns one of the
+ * #snd_pcm_state_t enum variants.
+ * It will never return a negative error code.
+ *
  * The function is thread-safe when built with the proper option.
  */
 snd_pcm_state_t snd_pcm_state(snd_pcm_t *pcm)