summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--hl/tools/gif2h5/writehdf.c2
-rw-r--r--tools/gifconv/writehdf.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/hl/tools/gif2h5/writehdf.c b/hl/tools/gif2h5/writehdf.c
index 5426c27..313b57e 100644
--- a/hl/tools/gif2h5/writehdf.c
+++ b/hl/tools/gif2h5/writehdf.c
@@ -95,7 +95,7 @@ char *GIFFileName;
fprintf(stderr , "strncpy failed\n");
exit(1);
}
- GroupName[VSNAMELENMAX] = '\0';
+ GroupName[VSNAMELENMAX - 1] = '\0';
if ((file_id = H5Fcreate(HDFName , H5F_ACC_TRUNC , H5P_DEFAULT , H5P_DEFAULT)) < 0) {
diff --git a/tools/gifconv/writehdf.c b/tools/gifconv/writehdf.c
index 5426c27..313b57e 100644
--- a/tools/gifconv/writehdf.c
+++ b/tools/gifconv/writehdf.c
@@ -95,7 +95,7 @@ char *GIFFileName;
fprintf(stderr , "strncpy failed\n");
exit(1);
}
- GroupName[VSNAMELENMAX] = '\0';
+ GroupName[VSNAMELENMAX - 1] = '\0';
if ((file_id = H5Fcreate(HDFName , H5F_ACC_TRUNC , H5P_DEFAULT , H5P_DEFAULT)) < 0) {