|
@@ -373,7 +373,10 @@ static void *starpu_hdf5_plug(void *parameter, starpu_ssize_t size STARPU_ATTRIB
|
|
|
#ifndef H5_HAVE_THREADSAFE
|
|
|
int nb_disk = STARPU_ATOMIC_ADD(&nb_disk_open, 1);
|
|
|
if (nb_disk != 1)
|
|
|
- _STARPU_ERROR("HDF5 library is not compiled with --enable-threadsafe. You can't open more than one HDF5 file in the same time !\n");
|
|
|
+ {
|
|
|
+ _STARPU_ERROR("HDF5 library is not compiled with --enable-threadsafe. You can't open more than one HDF5 file at the same time !\n");
|
|
|
+ return NULL;
|
|
|
+ }
|
|
|
#endif
|
|
|
|
|
|
struct starpu_hdf5_base * base;
|
|
@@ -392,6 +395,7 @@ static void *starpu_hdf5_plug(void *parameter, starpu_ssize_t size STARPU_ATTRIB
|
|
|
{
|
|
|
free(base);
|
|
|
_STARPU_ERROR("Can not create the HDF5 file (%s)", (char *) parameter);
|
|
|
+ return NULL;
|
|
|
}
|
|
|
|
|
|
/* just use _starpu_mktemp_many to create a file, close the file descriptor */
|
|
@@ -403,6 +407,7 @@ static void *starpu_hdf5_plug(void *parameter, starpu_ssize_t size STARPU_ATTRIB
|
|
|
{
|
|
|
free(base);
|
|
|
_STARPU_ERROR("Can not create the HDF5 file (%s)", (char *) parameter);
|
|
|
+ return NULL;
|
|
|
}
|
|
|
base->created = 1;
|
|
|
}
|
|
@@ -418,6 +423,7 @@ static void *starpu_hdf5_plug(void *parameter, starpu_ssize_t size STARPU_ATTRIB
|
|
|
{
|
|
|
free(base);
|
|
|
_STARPU_ERROR("Can not open the HDF5 file (%s)", (char *) parameter);
|
|
|
+ return NULL;
|
|
|
}
|
|
|
base->created = 0;
|
|
|
base->path = path;
|