From: Jingning Han Date: Tue, 2 Oct 2018 17:21:43 +0000 (-0700) Subject: Minor clean-up in tiny_ssim.c X-Git-Tag: v1.8.0~267^2 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=794b033f78b332b3935e4afd97f56940a3541953;p=libvpx Minor clean-up in tiny_ssim.c Report the correct filename in error message. Explicitly assign floating point value to double type. Change-Id: I42fd2da6e16b1e3e7ec221d5d562a728a93c0196 --- diff --git a/tools/tiny_ssim.c b/tools/tiny_ssim.c index 315d1c1f4..6f4b6d735 100644 --- a/tools/tiny_ssim.c +++ b/tools/tiny_ssim.c @@ -605,7 +605,7 @@ int main(int argc, char *argv[]) { } if (open_input_file(argv[1], &in[0], w, h, bit_depth) < 0) { - fprintf(stderr, "File %s can't be opened or parsed!\n", argv[2]); + fprintf(stderr, "File %s can't be opened or parsed!\n", argv[1]); goto clean_up; } @@ -617,7 +617,7 @@ int main(int argc, char *argv[]) { } if (bit_depth == 10) peak = 1023.0; - if (bit_depth == 12) peak = 4095; + if (bit_depth == 12) peak = 4095.0; if (open_input_file(argv[2], &in[1], w, h, bit_depth) < 0) { fprintf(stderr, "File %s can't be opened or parsed!\n", argv[2]);