summaryrefslogtreecommitdiff
path: root/src/libcamera/log.cpp
diff options
context:
space:
mode:
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>2020-01-19 00:38:04 +0200
committerLaurent Pinchart <laurent.pinchart@ideasonboard.com>2020-01-22 17:26:17 +0200
commit0228e9c927351d483fe696e5ca6eea9c2b2cbc87 (patch)
tree2113010903387bd38c015130074858c8a1891b12 /src/libcamera/log.cpp
parent7216c6a9bb815ca9d0b4247f8e04d87e4ac85fa2 (diff)
libcamera: Declare static local variables as const where applicable
We use static local variables to indicate errors in methods that return a const reference. The local variables can thus be const, make them so. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Jacopo Mondi <jacopo@jmondi.org> Reviewed-by: Niklas Söderlund <niklas.soderlund@ragnatech.se>
Diffstat (limited to 'src/libcamera/log.cpp')
-rw-r--r--src/libcamera/log.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libcamera/log.cpp b/src/libcamera/log.cpp
index 1dac4666..1c82dc68 100644
--- a/src/libcamera/log.cpp
+++ b/src/libcamera/log.cpp
@@ -749,7 +749,7 @@ void LogCategory::setSeverity(LogSeverity severity)
*/
const LogCategory &LogCategory::defaultCategory()
{
- static LogCategory category("default");
+ static const LogCategory category("default");
return category;
}