summaryrefslogtreecommitdiffstats
path: root/java/src/jni/h5sImp.c
diff options
context:
space:
mode:
authorAllen Byrne <byrn@hdfgroup.org>2017-05-25 20:57:18 (GMT)
committerAllen Byrne <byrn@hdfgroup.org>2017-05-25 20:57:18 (GMT)
commitdb2da9f4b4b582d644d4b2e976040fce4dd1d665 (patch)
treeef4f9b58cd68b998b277f167e8e8b23d39e168da /java/src/jni/h5sImp.c
parent53c5b41ec2068aa45982af071a1e3c707326851f (diff)
downloadhdf5-db2da9f4b4b582d644d4b2e976040fce4dd1d665.zip
hdf5-db2da9f4b4b582d644d4b2e976040fce4dd1d665.tar.gz
hdf5-db2da9f4b4b582d644d4b2e976040fce4dd1d665.tar.bz2
Reduce warnings
Diffstat (limited to 'java/src/jni/h5sImp.c')
-rw-r--r--java/src/jni/h5sImp.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/java/src/jni/h5sImp.c b/java/src/jni/h5sImp.c
index c578ab8..10f69eb 100644
--- a/java/src/jni/h5sImp.c
+++ b/java/src/jni/h5sImp.c
@@ -1206,8 +1206,8 @@ Java_hdf_hdf5lib_H5_H5Sencode
if (status < 0) {
h5libraryError(env);
} /* end else if */
- else if (buf_size < 0) {
- h5badArgument(env, "H5Sencode: buf_size < 0");
+ else if (buf_size == 0) {
+ h5badArgument(env, "H5Sencode: buf_size = 0");
} /* end if */
else {
bufPtr = (unsigned char*)HDcalloc((size_t) 1, buf_size);