]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
LogEntry.h: init LogEntry::seq with 0
authorDanny Al-Gaaf <danny.al-gaaf@bisect.de>
Wed, 17 Sep 2014 07:35:15 +0000 (09:35 +0200)
committerDanny Al-Gaaf <danny.al-gaaf@bisect.de>
Fri, 19 Sep 2014 16:27:08 +0000 (18:27 +0200)
CID 1238904 (#1 of 1): Uninitialized scalar variable (UNINIT)
 uninit_use_in_call: Using uninitialized value e.seq when calling
 log_to_syslog.

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
src/common/LogEntry.h

index 293afe41bfc7c93ec80c0318bb47a6cfd404cdad..7329595fd718b0ee6e54ecad1f5106b5fc50923a 100644 (file)
@@ -75,6 +75,8 @@ struct LogEntry {
   string msg;
   string channel;
 
+  LogEntry() : seq(0) {}
+
   LogEntryKey key() const { return LogEntryKey(who, stamp, seq); }
 
   void log_to_syslog(string level, string facility);