[RESEND][PATCH] ALSA: info: Fix llseek return value when using callback

Takashi Iwai tiwai at suse.de
Wed Aug 17 15:15:19 CEST 2022


On Wed, 17 Aug 2022 14:49:24 +0200,
Amadeusz Sławiński wrote:
> 
> When using callback there was a flow of
> 
> 	ret = -EINVAL
> 	if (callback) {
> 		offset = callback();
> 		goto out;
> 	}
> 	...
> 	offset = some other value in case of no callback;
> 	ret = offset;
> out:
> 	return ret;
> 
> which causes the snd_info_entry_llseek() to return -EINVAL when there is
> callback handler. Fix this by setting "ret" directly to callback return
> value before jumping to "out".
> 
> 73029e0ff18d ("ALSA: info - Implement common llseek for binary mode")

Fixes tag seems missing.  I corrected locally.

> Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski at linux.intel.com>

Applied now (with Cc to stable).


thanks,

Takashi


More information about the Alsa-devel mailing list