Re: [Spice-devel] [linux-agent v2 2/4] x11-randr: Improve argument check

2018-12-19 Thread Victor Toso
Hi, On Wed, Dec 19, 2018 at 03:19:37PM +0100, Victor Toso wrote: > From: Victor Toso > > In the current code, output should never be negative but the check > exists after we use the variable as index. Make the check earlier. > > Found by coverity: > | check_after_sink: You might be using vari

[Spice-devel] [linux-agent v2 2/4] x11-randr: Improve argument check

2018-12-19 Thread Victor Toso
From: Victor Toso In the current code, output should never be negative but the check exists after we use the variable as index. Make the check earlier. Found by coverity: | check_after_sink: You might be using variable "output" before | verifying that it is >= 0. Changes in v2: - Move overf