summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDana Robinson <derobins@hdfgroup.org>2019-07-12 04:17:08 (GMT)
committerDana Robinson <derobins@hdfgroup.org>2019-07-12 04:17:08 (GMT)
commit5314213f1ec03b31812f64d5d1282acc02921084 (patch)
treebe871d186f45bbb40429bb2d826b29f7fd296909
parent0784987c85e5b2189c5abe33ed8873da51dfe72e (diff)
parent3566fff6261d0bb8e360d3842e99919d2eb4ba73 (diff)
downloadhdf5-5314213f1ec03b31812f64d5d1282acc02921084.zip
hdf5-5314213f1ec03b31812f64d5d1282acc02921084.tar.gz
hdf5-5314213f1ec03b31812f64d5d1282acc02921084.tar.bz2
Merge pull request #1801 in HDFFV/hdf5 from ~DEROBINS/hdf5_der:develop_minor_pr to develop
* commit '3566fff6261d0bb8e360d3842e99919d2eb4ba73': Reverted snprintf to sprintf in the multi VFD since the former causes problems on Windows.
-rw-r--r--src/H5FDmulti.c24
1 files changed, 12 insertions, 12 deletions
diff --git a/src/H5FDmulti.c b/src/H5FDmulti.c
index acd128c..800869d 100644
--- a/src/H5FDmulti.c
+++ b/src/H5FDmulti.c
@@ -1966,30 +1966,30 @@ compute_next(H5FD_multi_t *file)
static int
open_members(H5FD_multi_t *file)
{
- char tmp[H5FD_MULT_MAX_FILE_NAME_LEN];
- int nerrors=0;
+ char tmp[H5FD_MULT_MAX_FILE_NAME_LEN];
+ int nerrors = 0;
static const char *func="(H5FD_multi)open_members"; /* Function Name for error reporting */
/* Clear the error stack */
H5Eclear2(H5E_DEFAULT);
UNIQUE_MEMBERS(file->fa.memb_map, mt) {
- if(file->memb[mt])
+ if(file->memb[mt])
continue; /*already open*/
- assert(file->fa.memb_name[mt]);
+ assert(file->fa.memb_name[mt]);
/* Note: This truncates the user's filename down to only sizeof(tmp)
* characters. -QK & JK, 2013/01/17
*/
- snprintf(tmp, sizeof(tmp), file->fa.memb_name[mt], file->name);
+ sprintf(tmp, file->fa.memb_name[mt], file->name);
tmp[sizeof(tmp) - 1] = '\0';
- H5E_BEGIN_TRY {
- file->memb[mt] = H5FDopen(tmp, file->flags, file->fa.memb_fapl[mt], HADDR_UNDEF);
- } H5E_END_TRY;
- if(!file->memb[mt]) {
- if(!file->fa.relax || (file->flags & H5F_ACC_RDWR))
- nerrors++;
- }
+ H5E_BEGIN_TRY {
+ file->memb[mt] = H5FDopen(tmp, file->flags, file->fa.memb_fapl[mt], HADDR_UNDEF);
+ } H5E_END_TRY;
+ if(!file->memb[mt]) {
+ if(!file->fa.relax || (file->flags & H5F_ACC_RDWR))
+ nerrors++;
+ }
} END_MEMBERS;
if (nerrors)
H5Epush_ret(func, H5E_ERR_CLS, H5E_INTERNAL, H5E_BADVALUE, "error opening member files", -1)