I was looking for some way to play an mp3 from memory rather than from file. got the following code from

http://support.microsoft.com/support.../Q155/3/60.asp

however it falls over trying to do memcpy in the READ section. I realise this is not in the C++ section, but does anyone have any ideas why it wont compile? the following error is the result of trying to compile:

C:\mk2.cpp(180) : error C2036: 'void *' : unknown size
Error executing cl.exe.




static char * lpData;
static long fileSize;
LRESULT CALLBACK IOProc(LPMMIOINFO lpMMIOInfo, UINT uMessage, LPARAM
lParam1, LPARAM lParam2)
{
static BOOL alreadyOpened = FALSE;

switch (uMessage) {
case MMIOM_OPEN:
if (alreadyOpened)
return 0;
alreadyOpened = TRUE;

lpMMIOInfo->lDiskOffset = 0;
return 0;

case MMIOM_CLOSE:
return 0;

case MMIOM_READ:
memcpy((void *)lParam1, lpData+lpMMIOInfo->lDiskOffset, lParam2); // ****** ERROR HERE *******
lpMMIOInfo->lDiskOffset += lParam2;

return (lParam2);

case MMIOM_SEEK:
switch (lParam2) {
case SEEK_SET:
lpMMIOInfo->lDiskOffset = lParam1;
break;

case SEEK_CUR:
lpMMIOInfo->lDiskOffset += lParam1;

case SEEK_END:
lpMMIOInfo->lDiskOffset = fileSize - 1 - lParam1;
break;
}
return lpMMIOInfo->lDiskOffset;

default:
return -1; // Unexpected msgs. For instance, we do not
// process MMIOM_WRITE in this sample
}// end of switch
}//end of IOProc