diff --git a/tests/fate-run.sh b/tests/fate-run.sh
index 1a8ff940bd92f4e301435c49d0dc9331bda61700..7f129d7831c0afaf8db7517d1e48bb72c3b06598 100755
--- a/tests/fate-run.sh
+++ b/tests/fate-run.sh
@@ -43,7 +43,7 @@ compare(){
 }
 
 do_tiny_psnr(){
-    psnr=$(tests/tiny_psnr "$1" "$2" $cmp_unit $cmp_shift 0)
+    psnr=$(tests/tiny_psnr "$1" "$2" $cmp_unit $cmp_shift 0) || return 1
     val=$(expr "$psnr" : ".*$3: *\([0-9.]*\)")
     size1=$(expr "$psnr" : '.*bytes: *\([0-9]*\)')
     size2=$(expr "$psnr" : '.*bytes:[ 0-9]*/ *\([0-9]*\)')