Skip to content

Commit

Permalink
Update matio library to 1.5.26 (#4285)
Browse files Browse the repository at this point in the history
  • Loading branch information
beutlich authored Mar 28, 2024
1 parent d838dc8 commit cf495f8
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 29 deletions.
30 changes: 4 additions & 26 deletions Modelica/Resources/C-Sources/ModelicaMatIO.c
Original file line number Diff line number Diff line change
Expand Up @@ -81,18 +81,6 @@
/* Extended sparse matrix data types */
/* #undef EXTENDED_SPARSE */

/* Define to 1 if you have the `fseeko' function. */
#undef HAVE_FSEEKO

/* Define to 1 if you have the `ftello' function. */
#undef HAVE_FTELLO

/* Define to 1 if you have the `fseeko64' function. */
#undef HAVE_FSEEKO64

/* Define to 1 if you have the `ftello64' function. */
#undef HAVE_FTELLO64

/* Define to 1 if you have the `_fseeki64' function. */
#if defined(_MSC_VER) && _MSC_VER >= 1400
#define HAVE__FSEEKI64 1
Expand All @@ -107,12 +95,6 @@
#undef HAVE__FTELLI64
#endif

/* Define if 64-bit file address support in 32-bit OS. */
#undef _FILE_OFFSET_BITS

/* Define if 64-bit file address support in 32-bit OS. */
#undef _LARGEFILE64_SOURCE

/* Define to 1 if you have the <inttypes.h> header file. */
#if defined(_WIN32)
#if defined(_MSC_VER) && _MSC_VER >= 1800
Expand Down Expand Up @@ -291,8 +273,7 @@
#define MATIO_LFS
#define fseeko _fseeki64
#define ftello _ftelli64
#elif !defined(HAVE_FSEEKO) && !defined(HAVE_FTELLO) && defined(HAVE_FSEEKO64) && \
defined(HAVE_FTELLO64)
#elif defined(HAVE_FSEEKO64) && defined(HAVE_FTELLO64)
#define MATIO_LFS
#define fseeko fseeko64
#define ftello ftello64
Expand Down Expand Up @@ -12465,11 +12446,7 @@ Mat_H5ReadVarInfo(matvar_t *matvar, hid_t dset_id)
type_id = H5Aget_type(attr_id);
class_str = (char *)calloc(H5Tget_size(type_id) + 1, 1);
if ( NULL != class_str ) {
herr_t herr;
hid_t class_id = H5Tcopy(H5T_C_S1);
H5Tset_size(class_id, H5Tget_size(type_id));
herr = H5Aread(attr_id, class_id, class_str);
H5Tclose(class_id);
herr_t herr = H5Aread(attr_id, type_id, class_str);
if ( herr < 0 ) {
free(class_str);
H5Tclose(type_id);
Expand Down Expand Up @@ -15718,7 +15695,8 @@ Mat_VarGetStructFieldByIndex(matvar_t *matvar, size_t field_index, size_t index)
matvar_t *field = NULL;
size_t nelems = 1, nfields;

if ( matvar == NULL || matvar->data == NULL || matvar->class_type != MAT_C_STRUCT || matvar->data_size == 0 )
if ( matvar == NULL || matvar->data == NULL || matvar->class_type != MAT_C_STRUCT ||
matvar->data_size == 0 )
return NULL;

err = Mat_MulDims(matvar, &nelems);
Expand Down
6 changes: 3 additions & 3 deletions Modelica/Resources/C-Sources/ModelicaMatIO.h
Original file line number Diff line number Diff line change
Expand Up @@ -55,13 +55,13 @@
#define MATIO_MINOR_VERSION 5

/* Matio release level number */
#define MATIO_RELEASE_LEVEL 24
#define MATIO_RELEASE_LEVEL 26

/* Matio version number */
#define MATIO_VERSION 1524
#define MATIO_VERSION 1526

/* Matio version string */
#define MATIO_VERSION_STR "1.5.24"
#define MATIO_VERSION_STR "1.5.26"

/* Default file format */
#define MAT_FT_DEFAULT MAT_FT_MAT5
Expand Down

0 comments on commit cf495f8

Please sign in to comment.