Open topic with navigation

TIBCO Rendezvous® 8.8.0

# tibrvMsg_Expand()

Function

## Declaration

    tibrv_status tibrvMsg_Expand(
        tibrvMsg            message,
        tibrv_u32           additionalStorage);

## Purpose

Enlarge a message by allocating additional storage.

## Remarks

When adding data to a message would overflow the allocated space, the message automatically expands by allocating additional storage. However, reallocation (whether explicit or automatic) is a slow operation; to optimize program performance, we recommend allocating sufficient storage initially, so that reallocation is not required.

In most cases, the message expands in place (without copying). In some cases, this function copies the message to a new location. In all cases, existing pointers to the message, its fields, and its field values remain valid (even after copying).

If no space is available, this function returns the error code TIBRV_NO_MEMORY.

Parameter | Description
`message` | Expand this message.
`additionalStorage` | Enlarge the message by this amount (in bytes) to allocate for the message. If the message was `oldSize` bytes before this call, it is `oldSize + additionalStorage` when the function returns.

Did you find this helpful?

Yes No
Great!
Thanks for taking the time to give us some feedback.
Sorry about that

Why wasn't this helpful? (check all that apply)

Could not find what I was looking for
Instructions confusing or unclear
Instructions did not work

Want to tell us more?

Please select at least one option or provide details about the issue!!

Error occurred while submitting feedback.

Error2 occurred while submitting feedback.

TIBCO Rendezvous®

Copyright © 1997-2025. Cloud Software Group, Inc. All Rights Reserved.