Use the mmioCFGetInfo function to retrieve the CTOC header of an open RIFF compound file. The mmioCFGetInfo function requires a pmmcfinfo parameter which identifies a pointer to a user-supplied buffer that will be filled with the CTOC header. Use the cBytes parameter to specify the size of the pmmcfinfo buffer. This is the maximum number of bytes that will be copied.
The information copied to pmmcfinfo consists of a MMCFINFO structure followed by variable length arrays aulExHdrFldUsage, aulExEntFldUsage, and aulExHdrField.
To find out how large a buffer the user needs to allocate, call mmioCFGetInfo with cBytes equal to the size of a ULONG. This returns the first field of the CTOC header, which happens to be the size of the header. This size can then be used as cBytes on the subsequent call.