From a7408c2d59c316684e3fa2b4fb2511f65e4e11d4 Mon Sep 17 00:00:00 2001 From: conrad Date: Tue, 30 Mar 2021 17:20:32 +1000 Subject: [PATCH] fix --- include/armadillo_bits/diskio_meat.hpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/include/armadillo_bits/diskio_meat.hpp b/include/armadillo_bits/diskio_meat.hpp index e7225755..df23f4ed 100644 --- a/include/armadillo_bits/diskio_meat.hpp +++ b/include/armadillo_bits/diskio_meat.hpp @@ -4377,7 +4377,7 @@ diskio::load_ppm_binary(Cube& x, std::istream& f, std::string& err_msg) f >> f_maxval; f.get(); - if( (f_maxval > 0) || (f_maxval <= 65535) ) + if( (f_maxval > 0) && (f_maxval <= 65535) ) { x.set_size(f_n_rows, f_n_cols, 3); @@ -4566,7 +4566,7 @@ diskio::load_ppm_binary(field& x, std::istream& f, std::string& err_msg) f >> f_maxval; f.get(); - if( (f_maxval > 0) || (f_maxval <= 65535) ) + if( (f_maxval > 0) && (f_maxval <= 65535) ) { x.set_size(3); Mat& R = x(0);