mirror of
https://github.com/joel16/VitaShell.git
synced 2024-11-23 03:39:39 +00:00
Fix sizeof(pointer) error in vita_audio.c
Getting the sizeof a pointer is always the same value, either dereference the pointer or use its type to get the correct size.
This commit is contained in:
parent
d240984c07
commit
a7422827c8
@ -481,8 +481,8 @@ vitaWav *vitaWavLoad(const char *filename)
|
||||
lSize = sceIoLseek32(fd, 0, SCE_SEEK_END);
|
||||
sceIoLseek32(fd, 0, SCE_SEEK_SET);
|
||||
|
||||
wav = malloc(lSize + sizeof(wav));
|
||||
wavfile = (unsigned char*)(wav) + sizeof(wav);
|
||||
wav = malloc(lSize + sizeof(vitaWav));
|
||||
wavfile = (unsigned char*)(wav) + sizeof(vitaWav);
|
||||
|
||||
filelen = sceIoRead(fd, wavfile, lSize);
|
||||
|
||||
@ -508,4 +508,4 @@ void vitaWavUnload(vitaWav *wav)
|
||||
{
|
||||
if(wav != NULL)
|
||||
free(wav);
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user