summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorQuincey Koziol <koziol@hdfgroup.org>2003-05-13 20:03:45 (GMT)
committerQuincey Koziol <koziol@hdfgroup.org>2003-05-13 20:03:45 (GMT)
commit394656ceba509c1c31005f844a707a7e3f6bfff5 (patch)
tree14ecbf00f94e956035d28773558e8a36ae33a939
parent4010a6d9d1925b7538062518ba4ac3c731fbe590 (diff)
downloadhdf5-394656ceba509c1c31005f844a707a7e3f6bfff5.zip
hdf5-394656ceba509c1c31005f844a707a7e3f6bfff5.tar.gz
hdf5-394656ceba509c1c31005f844a707a7e3f6bfff5.tar.bz2
[svn-r6868] Purpose:
Bug fix. Description: If the buffer holding the list of interfaces that are attempting to be closed down becomes full, the library stops recording that an infinite loop has occurred when shutting down the interfaces. Solution: Always return the correct "pending" information. Also added ellipsis to the string of interfaces to try to make it more obvious that the buffer became full. Platforms tested: FreeBSD 4.8 (sleipnir) h5committested
-rw-r--r--src/H5.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/src/H5.c b/src/H5.c
index e42f0da..bb82264 100644
--- a/src/H5.c
+++ b/src/H5.c
@@ -201,10 +201,14 @@ H5_term_library(void)
* way that would necessitate some cleanup work in the other interface.
*/
#define DOWN(F) \
- (((n=H5##F##_term_interface()) && at+5<sizeof loop)? \
+ (((n=H5##F##_term_interface()) && at+8<sizeof loop)? \
(sprintf(loop+at, "%s%s", at?",":"", #F), \
at += HDstrlen(loop+at), \
- n):0)
+ n): \
+ ((n>0 && at+5<sizeof loop)? \
+ (sprintf(loop+at, "..."), \
+ at += HDstrlen(loop+at), \
+ n):n))
do {
pending = 0;
@@ -228,7 +232,7 @@ H5_term_library(void)
/* Only display the error message if the user is interested in them. */
if (func) {
fprintf(stderr, "HDF5: infinite loop closing library\n");
- fprintf(stderr, " %s...\n", loop);
+ fprintf(stderr, " %s\n", loop);
}
}