mirror of
https://github.com/hyperion-project/hyperion.ng.git
synced 2025-03-01 10:33:28 +00:00
Fix Memory leaks (#1678)
* Refactor to fix #1671
* Add GUI/NonGUI mode to info page
* Do not show lock config, if in non-UI mode
* Updae Changelog
* Correct includes
* Ensure key member initialization - RGB Channels
* Ensure key member initialization - WebServer
* Update RGBChannels
* Fix initialization order
* Fix key when inserting new logger in LoggerMap,
Prepare logBuffer-JSON snapshot view in LoggerManager,
Increase buffered loglines to 500
* Fix Memory leak in GrabberWrapper
* Fix Memory leak in BlackBorderProcessor
* Fix Memory leak in BlackBorderProcessor
* use ninja generator under macos
* Fix BGEffectHandler destruction
* Fix Mdns code
* Clear list after applying qDeleteAll
* Fix deletion of CecHandler
* Fix memory leak caused by wrong buffer allocation
* Remove extra pixel consistently
* Change mDNS to Qt SmartPointers
* Correct removal
* Fix usage of _width/_height (they are the output resolution, not the screen resolution)
That avoids unnecessary resizing of the output image with every transferFrame call
* Move main non Thread Objects to Smart Pointers
* Revert "Move main non Thread Objects to Smart Pointers"
This reverts commit 26102ca963
.
* Add missing deletes
* Revert MdnsBrowser chnage
* Revert MdnsBrowser change
* Fix memory leaks related standalone grabber
* Address CodeQL finding
* delete pointer OsxFrameGrabber
---------
Co-authored-by: Paulchen-Panther <16664240+Paulchen-Panther@users.noreply.github.com>
This commit is contained in:
@@ -6,6 +6,7 @@
|
||||
#include <QMap>
|
||||
#include <QAtomicInteger>
|
||||
#include <QList>
|
||||
#include <QJsonArray>
|
||||
|
||||
#if (QT_VERSION >= QT_VERSION_CHECK(5, 14, 0))
|
||||
#include <QRecursiveMutex>
|
||||
@@ -14,8 +15,6 @@
|
||||
#endif
|
||||
|
||||
// stl includes
|
||||
#include <stdio.h>
|
||||
#include <stdarg.h>
|
||||
#ifdef _WIN32
|
||||
#include <stdexcept>
|
||||
#endif
|
||||
@@ -59,7 +58,7 @@ public:
|
||||
QString function;
|
||||
unsigned int line;
|
||||
QString fileName;
|
||||
uint64_t utime;
|
||||
qint64 utime;
|
||||
QString message;
|
||||
LogLevel level;
|
||||
QString levelString;
|
||||
@@ -74,7 +73,7 @@ public:
|
||||
void setMinLevel(LogLevel level) { _minLevel = static_cast<int>(level); }
|
||||
LogLevel getMinLevel() const { return static_cast<LogLevel>(int(_minLevel)); }
|
||||
QString getName() const { return _name; }
|
||||
QString getSubName() const { return _subname; }
|
||||
QString getSubName() const { return _subName; }
|
||||
|
||||
signals:
|
||||
void newLogMessage(Logger::T_LOG_MESSAGE);
|
||||
@@ -95,7 +94,7 @@ private:
|
||||
static QAtomicInteger<int> GLOBAL_MIN_LOG_LEVEL;
|
||||
|
||||
const QString _name;
|
||||
const QString _subname;
|
||||
const QString _subName;
|
||||
const bool _syslogEnabled;
|
||||
const unsigned _loggerId;
|
||||
|
||||
@@ -109,15 +108,15 @@ class LoggerManager : public QObject
|
||||
|
||||
public:
|
||||
static LoggerManager* getInstance();
|
||||
const QList<Logger::T_LOG_MESSAGE>* getLogMessageBuffer() const { return &_logMessageBuffer; }
|
||||
|
||||
public slots:
|
||||
void handleNewLogMessage(const Logger::T_LOG_MESSAGE&);
|
||||
QJsonArray getLogMessageBuffer(Logger::LogLevel filter=Logger::UNSET) const;
|
||||
|
||||
signals:
|
||||
void newLogMessage(const Logger::T_LOG_MESSAGE&);
|
||||
|
||||
protected:
|
||||
private:
|
||||
LoggerManager();
|
||||
|
||||
QList<Logger::T_LOG_MESSAGE> _logMessageBuffer;
|
||||
|
Reference in New Issue
Block a user