logo
Free, unlimited AI code reviews that run on commit
git-lrc git-lrc GitHub Install Now We'd appreciate a star git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt

Mat_Close — Closes an open MATLAB MAT file.

Description

       The Mat_Close() function closes a MATLAB MAT file opened with Mat_Open() or created with Mat_CreateVer().

Examples

       #include "matio.h"

       int main(int argc, char **argv)
       {
           mat_t *matfp;

           matfp = Mat_Open(argv[1], MAT_ACC_RDONLY);
           if ( NULL == matfp ) {
               fprintf(stderr, "Error opening MAT file %s0, argv[1]);
               return EXIT_FAILURE;
           }

           Mat_Close(matfp);
           return EXIT_SUCCESS;
       }

Name

       Mat_Close — Closes an open MATLAB MAT file.

Return Values

       The function returns 0 on success.  Otherwise, an error value is returned.

See Also

Mat_Open(3), Mat_CreateVer(3)

Debian                                         September 12, 2019                                   MAT_CLOSE(3)

Synopsis

#include<matio.h>intMat_Close(mat_t*matfp);

See Also