mirror of
https://github.com/Yetangitu/ampache
synced 2025-10-05 19:41:55 +02:00
Add check on waveform image creation
This commit is contained in:
parent
74b383e22e
commit
21df3dfc40
1 changed files with 4 additions and 0 deletions
|
@ -224,6 +224,10 @@ class Waveform
|
|||
// each waveform to be processed with be $height high, but will be condensed
|
||||
// and resized later (if specified)
|
||||
$img = imagecreatetruecolor($data_size / $detail, $height);
|
||||
if ($img === false) {
|
||||
debug_event('waveform', 'Cannot create image.', 1);
|
||||
return null;
|
||||
}
|
||||
|
||||
// fill background of image
|
||||
if ($background == "") {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue