Browse Source

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.
adaptive-webui-19844
nmariusp 2 years ago committed by GitHub
parent
commit
e2b140b8dd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      src/base/rss/rss_autodownloader.cpp

2
src/base/rss/rss_autodownloader.cpp

@ -108,8 +108,6 @@ AutoDownloader::AutoDownloader() @@ -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…
Cancel
Save