+
+ /* Adjust the old size to the user visible portion */
+ oldsize -= sizeof (unsigned);
+
+ /* If the new block is larger than the old one, copy the old
+ * data only
+ */
+ if (size > oldsize) {
+ size = oldsize;
+ }
+
+ /* Copy the block data */
+ memcpy (newblock, block, size);