NWC24CommitMsg

C Specification

#include <revolution/nwc24.h>
NWC24Err NWC24CommitMsg( NWC24MsgObj* obj );

Description

Creates message data reflecting the content of the configured message object, and places it in the outbox.

The data set with a function such as NWC24SetMsgText() is referenced and the message data is created. This means that you may deallocate the memory area storing these data after calling this function.

The NWC24SetMsg* type functions can no longer be called for message objects that were created by calling NWC24CommitMsg() once to create a message because it contains the information for referencing the newly created message. When creating a new message, NWC24InitMsgObj() will need to be called again to initialize the object.

Arguments

obj Pointer to the message object set for message creation

Return Values

NWC24_OK: Normal exit.
NWC24_ERR_LIB_NOT_OPENED: Library not open.
NWC24_ERR_PROTECTED: Message object is not set properly.
NWC24_ERR_OVERFLOW: Data size is over the limit that can be sent as a message.
NWC24_ERR_FULL: Cannot store data because the Outbox is full.
NWC24_ERR_NULL: No destination address set for the created message.
NWC24_ERR_INVALID_VALUE: The number of destination addresses set for the created message or the number of attached binaries has exceeded the limit.
NWC24_ERR_FORMAT: A field in an invalid format exists.
NWC24_ERR_NOMEM: Insufficient buffer error in an internal process.
NWC24_ERR_FILE_*: Error related to internal file operations.
NWC24_ERR_NAND_CORRUPT: Fatal damage to Wii save memory.


If any of the following values are returned, you can get the 6-digit error code corresponding to the error that occurred by immediately calling NWC24GetErrorCode().

File-related errors: NWC24_ERR_FILE_***, NWC24_ERR_BROKEN, NWC24_ERR_NAND_CORRUPT, NWC24_ERR_INTERNAL_VF.
The Outbox is full: NWC24_ERR_FULL.

See Also

NWC24InitMsgObj, NWC24SetMsgText, NWC24GetErrorCode

Revision History

2007/04/05 Added section about how to get error codes.
2006/10/06 Updated the list of return values.
2006/08/01 Initial version.


CONFIDENTIAL