Message ID | 5719e87b-4af9-4a4d-223d-f8cdbf3e6a2f@xs4all.nl (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | [for,v6.1] media: v4l2-ctrls-api.c: add back dropped ctrl->is_new = 1 | expand |
diff --git a/drivers/media/v4l2-core/v4l2-ctrls-api.c b/drivers/media/v4l2-core/v4l2-ctrls-api.c index d0a3aa3806fb..002ea6588edf 100644 --- a/drivers/media/v4l2-core/v4l2-ctrls-api.c +++ b/drivers/media/v4l2-core/v4l2-ctrls-api.c @@ -151,6 +151,7 @@ static int user_to_new(struct v4l2_ext_control *c, struct v4l2_ctrl *ctrl) */ if (strlen(ctrl->p_new.p_char) == ctrl->maximum && last) return -ERANGE; + ctrl->is_new = 1; } return ret; default:
The patch adding support for dynamically allocated arrays accidentally dropped the line setting ctrl->is_new to 1, thus new string values were always ignored. Fixes: fb582cba4492 ("media: v4l2-ctrls: add support for dynamically allocated arrays.") Reported-by: Alice Yuan <alice.yuan@nxp.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> --- drivers/media/v4l2-core/v4l2-ctrls-api.c | 1 + 1 file changed, 1 insertion(+)