summaryrefslogtreecommitdiffstats
path: root/src/H5Sall.c
diff options
context:
space:
mode:
authorDana Robinson <derobins@hdfgroup.org>2015-09-30 02:36:46 (GMT)
committerDana Robinson <derobins@hdfgroup.org>2015-09-30 02:36:46 (GMT)
commita89b064e2bd8fb81e39a930209114cfae4fcd141 (patch)
tree1b3c3b218a4e054ee998429982b7dff840304c16 /src/H5Sall.c
parent5c0a8cc86ebe85e1b46e20f253f09c86bdc83169 (diff)
parentfbd659fe6feba18f9fd4f931535a6603ccbf763d (diff)
downloadhdf5-a89b064e2bd8fb81e39a930209114cfae4fcd141.zip
hdf5-a89b064e2bd8fb81e39a930209114cfae4fcd141.tar.gz
hdf5-a89b064e2bd8fb81e39a930209114cfae4fcd141.tar.bz2
[svn-r27916] Re-merge of r27884-27891 from the trunk + bugfix for a few
H5S recursive functions where an aliased pointer was incorrectly set too early. Tested on: Ubuntu 15.04 (Linux 3.19 x86_64) w/ gcc 4.9.2 serial and parallel (w/ MPICH 3.1.4)
Diffstat (limited to 'src/H5Sall.c')
-rw-r--r--src/H5Sall.c18
1 files changed, 12 insertions, 6 deletions
diff --git a/src/H5Sall.c b/src/H5Sall.c
index 79796c3..fb6b45f 100644
--- a/src/H5Sall.c
+++ b/src/H5Sall.c
@@ -516,19 +516,25 @@ H5S_all_serial_size (const H5S_t H5_ATTR_UNUSED *space)
REVISION LOG
--------------------------------------------------------------------------*/
static herr_t
-H5S_all_serialize (const H5S_t *space, uint8_t **p)
+H5S_all_serialize(const H5S_t *space, uint8_t **p)
{
+ uint8_t *pp = (*p); /* Local pointer for decoding */
+
FUNC_ENTER_NOAPI_NOINIT_NOERR
+ /* Check args */
HDassert(space);
HDassert(p);
- HDassert(*p);
+ HDassert(pp);
/* Store the preamble information */
- UINT32ENCODE(*p, (uint32_t)H5S_GET_SELECT_TYPE(space)); /* Store the type of selection */
- UINT32ENCODE(*p, (uint32_t)1); /* Store the version number */
- UINT32ENCODE(*p, (uint32_t)0); /* Store the un-used padding */
- UINT32ENCODE(*p, (uint32_t)0); /* Store the additional information length */
+ UINT32ENCODE(pp, (uint32_t)H5S_GET_SELECT_TYPE(space)); /* Store the type of selection */
+ UINT32ENCODE(pp, (uint32_t)1); /* Store the version number */
+ UINT32ENCODE(pp, (uint32_t)0); /* Store the un-used padding */
+ UINT32ENCODE(pp, (uint32_t)0); /* Store the additional information length */
+
+ /* Update encoding pointer */
+ *p = pp;
FUNC_LEAVE_NOAPI(SUCCEED)
} /* H5S_all_serialize() */