summaryrefslogtreecommitdiffstats
path: root/src/H5RS.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/H5RS.c')
-rw-r--r--src/H5RS.c56
1 files changed, 28 insertions, 28 deletions
diff --git a/src/H5RS.c b/src/H5RS.c
index 172f1a5..18cf068 100644
--- a/src/H5RS.c
+++ b/src/H5RS.c
@@ -110,7 +110,7 @@ H5RS__xstrdup(H5RS_str_t *rs, const char *s)
FUNC_ENTER_PACKAGE
/* Sanity check */
- HDassert(rs);
+ assert(rs);
if (s) {
size_t len = HDstrlen(s);
@@ -138,9 +138,9 @@ H5RS__xstrdup(H5RS_str_t *rs, const char *s)
} /* end if */
else {
/* Sanity checks */
- HDassert(NULL == rs->end);
- HDassert(0 == rs->max);
- HDassert(0 == rs->len);
+ assert(NULL == rs->end);
+ assert(0 == rs->max);
+ assert(0 == rs->len);
} /* end else */
} /* end else */
@@ -174,7 +174,7 @@ H5RS__prepare_for_append(H5RS_str_t *rs)
FUNC_ENTER_PACKAGE
/* Sanity check */
- HDassert(rs);
+ assert(rs);
if (NULL == rs->s) {
rs->max = H5RS_ALLOC_SIZE;
@@ -226,7 +226,7 @@ H5RS__resize_for_append(H5RS_str_t *rs, size_t len)
FUNC_ENTER_PACKAGE
/* Sanity check */
- HDassert(rs);
+ assert(rs);
/* Check if buffer should be re-allocated */
if (len >= (rs->max - rs->len)) {
@@ -365,8 +365,8 @@ H5RS_asprintf_cat(H5RS_str_t *rs, const char *fmt, ...)
FUNC_ENTER_NOAPI(FAIL)
/* Sanity checks */
- HDassert(rs);
- HDassert(fmt);
+ assert(rs);
+ assert(fmt);
/* Prepare the [possibly wrapped or empty] ref-counted string for an append */
if (H5RS__prepare_for_append(rs) < 0)
@@ -419,8 +419,8 @@ H5RS_acat(H5RS_str_t *rs, const char *s)
FUNC_ENTER_NOAPI(FAIL)
/* Sanity checks */
- HDassert(rs);
- HDassert(s);
+ assert(rs);
+ assert(s);
/* Concatenate the provided string on to the managed string */
if (*s) {
@@ -468,8 +468,8 @@ H5RS_ancat(H5RS_str_t *rs, const char *s, size_t n)
FUNC_ENTER_NOAPI(FAIL)
/* Sanity checks */
- HDassert(rs);
- HDassert(s);
+ assert(rs);
+ assert(s);
/* Concatenate the provided string on to the managed string */
if (n && *s) {
@@ -519,8 +519,8 @@ H5RS_aputc(H5RS_str_t *rs, int c)
FUNC_ENTER_NOAPI(FAIL)
/* Sanity checks */
- HDassert(rs);
- HDassert(c);
+ assert(rs);
+ assert(c);
/* Allocate the underlying string, if necessary */
if (H5RS__prepare_for_append(rs) < 0)
@@ -565,8 +565,8 @@ H5RS_decr(H5RS_str_t *rs)
FUNC_ENTER_NOAPI_NOINIT_NOERR
/* Sanity check */
- HDassert(rs);
- HDassert(rs->n > 0);
+ assert(rs);
+ assert(rs->n > 0);
/* Decrement reference count for string */
if ((--rs->n) == 0) {
@@ -604,8 +604,8 @@ H5RS_incr(H5RS_str_t *rs)
FUNC_ENTER_NOAPI(FAIL)
/* Sanity check */
- HDassert(rs);
- HDassert(rs->n > 0);
+ assert(rs);
+ assert(rs->n > 0);
/* If the ref-counted string started life as a wrapper around an existing
* string, duplicate the string now, so that the wrapped string can go out
@@ -684,10 +684,10 @@ H5RS_cmp(const H5RS_str_t *rs1, const H5RS_str_t *rs2)
FUNC_ENTER_NOAPI_NOINIT_NOERR
/* Sanity check */
- HDassert(rs1);
- HDassert(rs1->s);
- HDassert(rs2);
- HDassert(rs2->s);
+ assert(rs1);
+ assert(rs1->s);
+ assert(rs2);
+ assert(rs2->s);
FUNC_LEAVE_NOAPI(HDstrcmp(rs1->s, rs2->s))
} /* end H5RS_cmp() */
@@ -716,8 +716,8 @@ H5RS_len(const H5RS_str_t *rs)
FUNC_ENTER_NOAPI_NOINIT_NOERR
/* Sanity check */
- HDassert(rs);
- HDassert(rs->s);
+ assert(rs);
+ assert(rs->s);
FUNC_LEAVE_NOAPI(HDstrlen(rs->s))
} /* end H5RS_len() */
@@ -749,8 +749,8 @@ H5RS_get_str(const H5RS_str_t *rs)
FUNC_ENTER_NOAPI_NOINIT_NOERR
/* Sanity check */
- HDassert(rs);
- HDassert(rs->s);
+ assert(rs);
+ assert(rs->s);
FUNC_LEAVE_NOAPI(rs->s)
} /* end H5RS_get_str() */
@@ -780,8 +780,8 @@ H5RS_get_count(const H5RS_str_t *rs)
FUNC_ENTER_NOAPI_NOINIT_NOERR
/* Sanity check */
- HDassert(rs);
- HDassert(rs->n > 0);
+ assert(rs);
+ assert(rs->n > 0);
FUNC_LEAVE_NOAPI(rs->n)
} /* end H5RS_get_count() */