# HG changeset patch # User Rik # Date 1393859226 28800 # Node ID 7b60d0d9f0f2eb675f8701f120a52aada4d3a3bf # Parent fcd87f68af4f225f911daf47e2642fc0f6f1d12a imwrite.m: Fix bug with numfields introduction in cset fcd87f68af4f. imwrite.m: Change sense of if test from > 0 to == 0. diff -r fcd87f68af4f -r 7b60d0d9f0f2 scripts/image/imwrite.m --- a/scripts/image/imwrite.m Sun Mar 02 12:56:11 2014 -0800 +++ b/scripts/image/imwrite.m Mon Mar 03 07:07:06 2014 -0800 @@ -100,7 +100,7 @@ fmt = imformats (ext); ## When there is no match, fmt will be a 1x1 structure with ## no fields, so we can't just use `isempty (fmt)'. - if (numfields (fmt) > 0) + if (numfields (fmt) == 0) if (isempty (ext)) error ("imwrite: no extension found for %s to identify the image format", filename);