diff liboctave/boolSparse.cc @ 8999:dc07bc4157b8

allow empty matrices in stream input operators
author Jaroslav Hajek <highegg@gmail.com>
date Fri, 20 Mar 2009 11:39:25 +0100
parents eb63fbe60fab
children c6edba80dfae
line wrap: on
line diff
--- a/liboctave/boolSparse.cc	Thu Mar 19 17:46:38 2009 +0100
+++ b/liboctave/boolSparse.cc	Fri Mar 20 11:39:25 2009 +0100
@@ -184,9 +184,7 @@
   octave_idx_type nc = a.cols ();
   octave_idx_type nz = a.nzmax ();
 
-  if (nr < 1 || nc < 1)
-    is.clear (std::ios::badbit);
-  else
+  if (nr > 0 && nc > 0)
     {
       octave_idx_type itmp, jtmp, jold = 0;
       bool tmp;