mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-11 23:54:18 +00:00
Added a check in ImagePreviewComponent to avoid reading directories
This commit is contained in:
parent
f506cc7f5d
commit
beab10fca7
1 changed files with 1 additions and 1 deletions
|
|
@ -63,7 +63,7 @@ void ImagePreviewComponent::timerCallback()
|
|||
|
||||
ScopedPointer<FileInputStream> in (fileToLoad.createInputStream());
|
||||
|
||||
if (in != nullptr)
|
||||
if (in != nullptr && in->getFile().existsAsFile())
|
||||
{
|
||||
if (ImageFileFormat* const format = ImageFileFormat::findImageFormatForStream (*in))
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue