summaryrefslogtreecommitdiffstats
path: root/src/H5Ptest.c
diff options
context:
space:
mode:
authorDana Robinson <derobins@hdfgroup.org>2022-04-13 21:17:29 (GMT)
committerDana Robinson <derobins@hdfgroup.org>2022-04-13 21:17:29 (GMT)
commitcabc39c3e197e2591449d2604bfee26465fb60e1 (patch)
treed5f39f5f5965584bf9bf49646a2af617adfd3e4e /src/H5Ptest.c
parent7355f4c505092a7a85474b47f18d5206028e2c95 (diff)
parentab69f5df770ee3cc6cd6c81d905a5317b894a002 (diff)
downloadhdf5-feature/coding_standards.zip
hdf5-feature/coding_standards.tar.gz
hdf5-feature/coding_standards.tar.bz2
Merge branch 'develop' into feature/coding_standardsfeature/coding_standards
Diffstat (limited to 'src/H5Ptest.c')
-rw-r--r--src/H5Ptest.c52
1 files changed, 24 insertions, 28 deletions
diff --git a/src/H5Ptest.c b/src/H5Ptest.c
index 114b37b..645988a 100644
--- a/src/H5Ptest.c
+++ b/src/H5Ptest.c
@@ -6,33 +6,31 @@
* This file is part of HDF5. The full HDF5 copyright notice, including *
* terms governing use, modification, and redistribution, is contained in *
* the COPYING file, which can be found at the root of the source code *
- * distribution tree, or in https://support.hdfgroup.org/ftp/HDF5/releases. *
+ * distribution tree, or in https://www.hdfgroup.org/licenses. *
* If you do not have access to either file, you may request a copy from *
* help@hdfgroup.org. *
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
-/* Programmer: Quincey Koziol <koziol@ncsa.uiuc.edu>
+/* Programmer: Quincey Koziol
* Saturday May 31, 2003
*
* Purpose: Generic Property Testing Functions
*/
-#include "H5Pmodule.h" /* This source code file is part of the H5P module */
-#define H5P_TESTING /*suppress warning about H5P testing funcs*/
-
+#include "H5Pmodule.h" /* This source code file is part of the H5P module */
+#define H5P_TESTING /*suppress warning about H5P testing funcs*/
/* Private header files */
-#include "H5private.h" /* Generic Functions */
-#include "H5Eprivate.h" /* Error handling */
-#include "H5Iprivate.h" /* IDs */
-#include "H5Ppkg.h" /* Property lists */
-#include "H5Dprivate.h" /* Dataset */
+#include "H5private.h" /* Generic Functions */
+#include "H5Eprivate.h" /* Error handling */
+#include "H5Iprivate.h" /* IDs */
+#include "H5Ppkg.h" /* Property lists */
+#include "H5Dprivate.h" /* Dataset */
/* Local variables */
/* Local typedefs */
-
/*--------------------------------------------------------------------------
NAME
H5P__get_class_path_test
@@ -58,31 +56,30 @@
char *
H5P__get_class_path_test(hid_t pclass_id)
{
- H5P_genclass_t *pclass; /* Property class to query */
- char *ret_value = NULL; /* Return value */
+ H5P_genclass_t *pclass; /* Property class to query */
+ char * ret_value = NULL; /* Return value */
FUNC_ENTER_PACKAGE
/* Check arguments. */
- if(NULL == (pclass = (H5P_genclass_t *)H5I_object_verify(pclass_id, H5I_GENPROP_CLS)))
+ if (NULL == (pclass = (H5P_genclass_t *)H5I_object_verify(pclass_id, H5I_GENPROP_CLS)))
HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, NULL, "not a property class");
/* Get the property list class path */
- if(NULL == (ret_value = H5P__get_class_path(pclass)))
+ if (NULL == (ret_value = H5P__get_class_path(pclass)))
HGOTO_ERROR(H5E_PLIST, H5E_NOTFOUND, NULL, "unable to query full path of class")
done:
FUNC_LEAVE_NOAPI(ret_value)
-} /* H5P__get_class_path_test() */
+} /* H5P__get_class_path_test() */
-
/*--------------------------------------------------------------------------
NAME
H5P__open_class_path_test
PURPOSE
Routine to open a [copy of] a class with its full path name
USAGE
- hid_t H5P__open_class_name_test(path)
+ hid_t H5P__open_class_path_test(path)
const char *path; IN: Full path name of class to open [copy of]
RETURNS
Success: ID of generic property class
@@ -99,27 +96,26 @@ done:
hid_t
H5P__open_class_path_test(const char *path)
{
- H5P_genclass_t *pclass = NULL; /* Property class to query */
- hid_t ret_value = H5I_INVALID_HID; /* Return value */
+ H5P_genclass_t *pclass = NULL; /* Property class to query */
+ hid_t ret_value = H5I_INVALID_HID; /* Return value */
FUNC_ENTER_PACKAGE
/* Check arguments. */
- if(NULL == path || *path=='\0')
+ if (NULL == path || *path == '\0')
HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, H5I_INVALID_HID, "invalid class path");
/* Open the property list class */
- if(NULL == (pclass = H5P__open_class_path(path)))
+ if (NULL == (pclass = H5P__open_class_path(path)))
HGOTO_ERROR(H5E_PLIST, H5E_NOTFOUND, H5I_INVALID_HID, "unable to find class with full path");
- /* Get an atom for the class */
- if((ret_value = H5I_register(H5I_GENPROP_CLS, pclass, TRUE)) < 0)
- HGOTO_ERROR(H5E_PLIST, H5E_CANTREGISTER, H5I_INVALID_HID, "unable to atomize property list class");
+ /* Get an ID for the class */
+ if ((ret_value = H5I_register(H5I_GENPROP_CLS, pclass, TRUE)) < 0)
+ HGOTO_ERROR(H5E_PLIST, H5E_CANTREGISTER, H5I_INVALID_HID, "unable to register property list class");
done:
- if(H5I_INVALID_HID == ret_value && pclass)
+ if (H5I_INVALID_HID == ret_value && pclass)
H5P__close_class(pclass);
FUNC_LEAVE_NOAPI(ret_value)
-} /* H5P__open_class_path_test() */
-
+} /* H5P__open_class_path_test() */