diff mbox

[libdrm] tests/exynos: remove dead condition

Message ID 1521006517-24074-1-git-send-email-sw0312.kim@samsung.com (mailing list archive)
State New, archived
Headers show

Commit Message

Seung-Woo Kim March 14, 2018, 5:48 a.m. UTC
There is already condition checking input values between 2 and 4096
so condition checking 0 is always false. Remove the dead condition.

Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
---
 tests/exynos/exynos_fimg2d_perf.c |    7 -------
 1 files changed, 0 insertions(+), 7 deletions(-)

Comments

Eric Engestrom March 15, 2018, 4:34 p.m. UTC | #1
On Wednesday, 2018-03-14 14:48:37 +0900, Seung-Woo Kim wrote:
> There is already condition checking input values between 2 and 4096
> so condition checking 0 is always false. Remove the dead condition.
> 
> Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>

Indeed, good catch :)
Reviewed-by: Eric Engestrom <eric.engestrom@imgtec.com>

... and pushed, thanks!

> ---
>  tests/exynos/exynos_fimg2d_perf.c |    7 -------
>  1 files changed, 0 insertions(+), 7 deletions(-)
> 
> diff --git a/tests/exynos/exynos_fimg2d_perf.c b/tests/exynos/exynos_fimg2d_perf.c
> index a2d5c19..97691a7 100644
> --- a/tests/exynos/exynos_fimg2d_perf.c
> +++ b/tests/exynos/exynos_fimg2d_perf.c
> @@ -274,13 +274,6 @@ int main(int argc, char **argv)
>  		goto out;
>  	}
>  
> -	if (bufw == 0 || bufh == 0) {
> -		fprintf(stderr, "error: buffer width/height should be non-zero.\n");
> -		ret = -1;
> -
> -		goto out;
> -	}
> -
>  	fd = drmOpen("exynos", NULL);
>  	if (fd < 0) {
>  		fprintf(stderr, "error: failed to open drm\n");
> -- 
> 1.7.4.1
> 
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel
diff mbox

Patch

diff --git a/tests/exynos/exynos_fimg2d_perf.c b/tests/exynos/exynos_fimg2d_perf.c
index a2d5c19..97691a7 100644
--- a/tests/exynos/exynos_fimg2d_perf.c
+++ b/tests/exynos/exynos_fimg2d_perf.c
@@ -274,13 +274,6 @@  int main(int argc, char **argv)
 		goto out;
 	}
 
-	if (bufw == 0 || bufh == 0) {
-		fprintf(stderr, "error: buffer width/height should be non-zero.\n");
-		ret = -1;
-
-		goto out;
-	}
-
 	fd = drmOpen("exynos", NULL);
 	if (fd < 0) {
 		fprintf(stderr, "error: failed to open drm\n");