aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorrhaas <rhaas@8e189c6b-2ab8-4400-aa02-70a9cfce18b9>2012-05-17 04:16:18 +0000
committerrhaas <rhaas@8e189c6b-2ab8-4400-aa02-70a9cfce18b9>2012-05-17 04:16:18 +0000
commitc05fef8ce98e1cf48854a0e9b7f62e90964bdf90 (patch)
tree34072e0ecd566763c28234f851c593d51a23518b
parent8d3df818ac0161221d2a8208d81a615d82796920 (diff)
* close all HDF5 objects
* check H5?close() return code * make file-local functions static git-svn-id: http://svn.einsteintoolkit.org/cactus/EinsteinEOS/EOS_Omni/trunk@59 8e189c6b-2ab8-4400-aa02-70a9cfce18b9
-rw-r--r--src/nuc_eos/readtable.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/nuc_eos/readtable.c b/src/nuc_eos/readtable.c
index f63c4d4..5cdc229 100644
--- a/src/nuc_eos/readtable.c
+++ b/src/nuc_eos/readtable.c
@@ -23,8 +23,8 @@ void CCTK_FNAME(allocate_eosmodule)
#fn_call, _error_code); \
} while (0)
-int file_is_readable(const char* filename);
-int file_is_readable(const char* filename)
+static int file_is_readable(const char* filename);
+static int file_is_readable(const char* filename)
{
FILE* fp = NULL;
fp = fopen(filename, "r");
@@ -38,7 +38,6 @@ int file_is_readable(const char* filename)
// Cactus calls this function. It reads in the table and calls a fortran
// function to setup values for the fortran eos module
-void EOS_OMNI_ReadTable(CCTK_ARGUMENTS);
void EOS_OMNI_ReadTable(CCTK_ARGUMENTS)
{
DECLARE_CCTK_PARAMETERS
@@ -131,7 +130,8 @@ void EOS_OMNI_ReadTable(CCTK_ARGUMENTS)
READ_EOS_HDF5("ye", ye, H5T_NATIVE_DOUBLE, H5S_ALL);
READ_EOS_HDF5("energy_shift", &energy_shift, H5T_NATIVE_DOUBLE, H5S_ALL);
- H5Fclose(file);
+ HDF5_ERROR(H5Sclose(mem3));
+ HDF5_ERROR(H5Fclose(file));
// Give all values to fortran - which will copy them until I can find out how
// I can tell Fortran to use those pointers inside the module