Fix overflow found by PVS Studio
Was V512 at https://www.viva64.com/en/b/0741/
This commit is contained in:
parent
70076bf624
commit
8d6422e1b2
|
@ -245,7 +245,7 @@ void SoundControlsClass::Process(void)
|
|||
int length = Theme.Track_Length(index);
|
||||
char const * fullname = Theme.Full_Name(index);
|
||||
|
||||
void * ptr = new char [sizeof(100)];
|
||||
void * ptr = new char [100];
|
||||
if (ptr) {
|
||||
sprintf((char *)ptr, "%cTrack %d\t%d:%02d\t%s", index, listbox.Count()+1, length / 60, length % 60, fullname);
|
||||
listbox.Add_Item((char const *)ptr);
|
||||
|
|
Loading…
Reference in New Issue