comparison src/ov-bool-sparse.cc @ 5322:22994a5730f9

[project @ 2005-04-29 13:04:24 by dbateman]
author dbateman
date Fri, 29 Apr 2005 13:04:25 +0000
parents 4c8a2e4e0717
children 05adf9de7657
comparison
equal deleted inserted replaced
5321:84b72a402b86 5322:22994a5730f9
247 return true; 247 return true;
248 } 248 }
249 249
250 bool 250 bool
251 octave_sparse_bool_matrix::load_binary (std::istream& is, bool swap, 251 octave_sparse_bool_matrix::load_binary (std::istream& is, bool swap,
252 oct_mach_info::float_format fmt) 252 oct_mach_info::float_format /* fmt */)
253 { 253 {
254 FOUR_BYTE_INT nz, nc, nr, tmp; 254 FOUR_BYTE_INT nz, nc, nr, tmp;
255 if (! is.read (X_CAST (char *, &tmp), 4)) 255 if (! is.read (X_CAST (char *, &tmp), 4))
256 return false; 256 return false;
257 257
594 OCTAVE_LOCAL_BUFFER (hsize_t, hdims, rank); 594 OCTAVE_LOCAL_BUFFER (hsize_t, hdims, rank);
595 OCTAVE_LOCAL_BUFFER (hsize_t, maxdims, rank); 595 OCTAVE_LOCAL_BUFFER (hsize_t, maxdims, rank);
596 596
597 H5Sget_simple_extent_dims (space_hid, hdims, maxdims); 597 H5Sget_simple_extent_dims (space_hid, hdims, maxdims);
598 598
599 if (hdims[0] != nc + 1 || hdims[1] != 1) 599 if (static_cast<int> (hdims[0]) != nc + 1 ||
600 static_cast<int> (hdims[1]) != 1)
600 { 601 {
601 H5Sclose (space_hid); 602 H5Sclose (space_hid);
602 H5Dclose (data_hid); 603 H5Dclose (data_hid);
603 H5Gclose (group_hid); 604 H5Gclose (group_hid);
604 return false; 605 return false;
629 return false; 630 return false;
630 } 631 }
631 632
632 H5Sget_simple_extent_dims (space_hid, hdims, maxdims); 633 H5Sget_simple_extent_dims (space_hid, hdims, maxdims);
633 634
634 if (hdims[0] != nz || hdims[1] != 1) 635 if (static_cast<int> (hdims[0]) != nz || static_cast<int> (hdims[1]) != 1)
635 { 636 {
636 H5Sclose (space_hid); 637 H5Sclose (space_hid);
637 H5Dclose (data_hid); 638 H5Dclose (data_hid);
638 H5Gclose (group_hid); 639 H5Gclose (group_hid);
639 return false; 640 return false;
664 return false; 665 return false;
665 } 666 }
666 667
667 H5Sget_simple_extent_dims (space_hid, hdims, maxdims); 668 H5Sget_simple_extent_dims (space_hid, hdims, maxdims);
668 669
669 if (hdims[0] != nz || hdims[1] != 1) 670 if (static_cast<int> (hdims[0]) != nz || static_cast<int> (hdims[1]) != 1)
670 { 671 {
671 H5Sclose (space_hid); 672 H5Sclose (space_hid);
672 H5Dclose (data_hid); 673 H5Dclose (data_hid);
673 H5Gclose (group_hid); 674 H5Gclose (group_hid);
674 return false; 675 return false;