mirror of
https://github.com/d47081/qBittorrent.git
synced 2025-01-22 20:44:15 +00:00
Remove meaningless checking for nullptr
Fix PVS-Studio issue "rss_autodownloader.cpp:111: warning: V668 There is no sense in testing the 'm_fileStorage' pointer against null, as the memory was allocated using the 'new' operator. The exception will be generated in the case of memory allocation error". PR #17347.
This commit is contained in:
parent
d2a29c2f87
commit
e2b140b8dd
@ -108,8 +108,6 @@ AutoDownloader::AutoDownloader()
|
||||
m_instance = this;
|
||||
|
||||
m_fileStorage = new AsyncFileStorage(specialFolderLocation(SpecialFolder::Config) / Path(CONF_FOLDER_NAME));
|
||||
if (!m_fileStorage)
|
||||
throw RuntimeError(tr("Directory for RSS AutoDownloader data is unavailable."));
|
||||
|
||||
m_fileStorage->moveToThread(m_ioThread);
|
||||
connect(m_ioThread, &QThread::finished, m_fileStorage, &AsyncFileStorage::deleteLater);
|
||||
|
Loading…
x
Reference in New Issue
Block a user