ui/vnc-jobs: vnc_has_job_locked() argument cannot be NULL
The only caller, vnc_jobs_join() cannot take vs == NULL argument, or it would later crash. Reviewed-by: Daniel P. Berrangé <berrange@redhat.com> Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Marc-André Lureau committed
Mar 13, 2026 at 23:09 UTC
3620f3bab7d615ecab795a5aebbfe2769eae1e40
1 file changed
+1
-1
ui/vnc-jobs.c
+1
-1
@@ -138,7 +138,7 @@ static bool vnc_has_job_locked(VncState *vs)
138
VncJob *job;
139
140
QTAILQ_FOREACH(job, &queue->jobs, next) {
141
- if (job->vs == vs || !vs) {
141
+ if (job->vs == vs) {
142
return true;
143
}
144
}