mirror of
https://github.com/YACReader/yacreader
synced 2025-05-27 19:00:29 -04:00
Fix load7zLibrary()
QLibrary just checks the extension, but it doesn't check that the file exists...
This commit is contained in:
parent
dedb1cbb2e
commit
97a416f7e4
@ -126,7 +126,8 @@ QLibrary *YACReader::load7zLibrary()
|
|||||||
{
|
{
|
||||||
#if defined Q_OS_UNIX && !defined Q_OS_MACOS
|
#if defined Q_OS_UNIX && !defined Q_OS_MACOS
|
||||||
auto yacreader7zPath = QString(LIBDIR) + "/yacreader/7z.so";
|
auto yacreader7zPath = QString(LIBDIR) + "/yacreader/7z.so";
|
||||||
if (QLibrary::isLibrary(yacreader7zPath)) {
|
QFileInfo sevenzlibrary(yacreader7zPath);
|
||||||
|
if (sevenzlibrary.exists()) {
|
||||||
return new QLibrary(yacreader7zPath);
|
return new QLibrary(yacreader7zPath);
|
||||||
} else {
|
} else {
|
||||||
return new QLibrary(QString(LIBDIR) + "/7zip/7z.so");
|
return new QLibrary(QString(LIBDIR) + "/7zip/7z.so");
|
||||||
|
Loading…
Reference in New Issue
Block a user