Skip to content
This repository was archived by the owner on Jun 30, 2025. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions src/glog/logging.h.in
Original file line number Diff line number Diff line change
Expand Up @@ -1309,16 +1309,16 @@ GLOG_MSVC_PUSH_DISABLE_WARNING(4275)
class GOOGLE_GLOG_DLL_DECL LogStream : public std::ostream {
GLOG_MSVC_POP_WARNING()
public:
LogStream(char *buf, int len, int ctr)
LogStream(char *buf, int len, uint64 ctr)
: std::ostream(NULL),
streambuf_(buf, len),
ctr_(ctr),
self_(this) {
rdbuf(&streambuf_);
}

int ctr() const { return ctr_; }
void set_ctr(int ctr) { ctr_ = ctr; }
uint64 ctr() const { return ctr_; }
void set_ctr(uint64 ctr) { ctr_ = ctr; }
LogStream* self() const { return self_; }

// Legacy std::streambuf methods.
Expand All @@ -1330,15 +1330,15 @@ GLOG_MSVC_POP_WARNING()
LogStream(const LogStream&);
LogStream& operator=(const LogStream&);
base_logging::LogStreamBuf streambuf_;
int ctr_; // Counter hack (for the LOG_EVERY_X() macro)
uint64 ctr_; // Counter hack (for the LOG_EVERY_X() macro)
LogStream *self_; // Consistency check hack
};

public:
// icc 8 requires this typedef to avoid an internal compiler error.
typedef void (LogMessage::*SendMethod)();

LogMessage(const char* file, int line, LogSeverity severity, int ctr,
LogMessage(const char* file, int line, LogSeverity severity, uint64 ctr,
SendMethod send_method);

// Two special constructors that generate reduced amounts of code at
Expand Down Expand Up @@ -1509,7 +1509,7 @@ GOOGLE_GLOG_DLL_DECL std::ostream& operator<<(std::ostream &os,
class GOOGLE_GLOG_DLL_DECL ErrnoLogMessage : public LogMessage {
public:

ErrnoLogMessage(const char* file, int line, LogSeverity severity, int ctr,
ErrnoLogMessage(const char* file, int line, LogSeverity severity, uint64 ctr,
void (LogMessage::*send_method)());

// Postpends ": strerror(errno) [errno]".
Expand Down
4 changes: 2 additions & 2 deletions src/logging.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1480,7 +1480,7 @@ LogMessage::LogMessageData::LogMessageData()
}

LogMessage::LogMessage(const char* file, int line, LogSeverity severity,
int ctr, void (LogMessage::*send_method)())
uint64 ctr, void (LogMessage::*send_method)())
: allocated_(NULL) {
Init(file, line, severity, send_method);
data_->stream_.set_ctr(ctr);
Expand Down Expand Up @@ -1978,7 +1978,7 @@ ostream& operator<<(ostream &os, const PRIVATE_Counter&) {
}

ErrnoLogMessage::ErrnoLogMessage(const char* file, int line,
LogSeverity severity, int ctr,
LogSeverity severity, uint64 ctr,
void (LogMessage::*send_method)())
: LogMessage(file, line, severity, ctr, send_method) {
}
Expand Down
12 changes: 6 additions & 6 deletions src/windows/glog/logging.h
Original file line number Diff line number Diff line change
Expand Up @@ -1173,16 +1173,16 @@ GLOG_MSVC_PUSH_DISABLE_WARNING(4275)
class GOOGLE_GLOG_DLL_DECL LogStream : public std::ostream {
GLOG_MSVC_POP_WARNING()
public:
LogStream(char *buf, int len, int ctr)
LogStream(char *buf, int len, uint64 ctr)
: std::ostream(NULL),
streambuf_(buf, len),
ctr_(ctr),
self_(this) {
rdbuf(&streambuf_);
}

int ctr() const { return ctr_; }
void set_ctr(int ctr) { ctr_ = ctr; }
uint64 ctr() const { return ctr_; }
void set_ctr(uint64 ctr) { ctr_ = ctr; }
LogStream* self() const { return self_; }

// Legacy std::streambuf methods.
Expand All @@ -1194,15 +1194,15 @@ GLOG_MSVC_POP_WARNING()
LogStream(const LogStream&);
LogStream& operator=(const LogStream&);
base_logging::LogStreamBuf streambuf_;
int ctr_; // Counter hack (for the LOG_EVERY_X() macro)
uint64 ctr_; // Counter hack (for the LOG_EVERY_X() macro)
LogStream *self_; // Consistency check hack
};

public:
// icc 8 requires this typedef to avoid an internal compiler error.
typedef void (LogMessage::*SendMethod)();

LogMessage(const char* file, int line, LogSeverity severity, int ctr,
LogMessage(const char* file, int line, LogSeverity severity, uint64 ctr,
SendMethod send_method);

// Two special constructors that generate reduced amounts of code at
Expand Down Expand Up @@ -1373,7 +1373,7 @@ GOOGLE_GLOG_DLL_DECL std::ostream& operator<<(std::ostream &os,
class GOOGLE_GLOG_DLL_DECL ErrnoLogMessage : public LogMessage {
public:

ErrnoLogMessage(const char* file, int line, LogSeverity severity, int ctr,
ErrnoLogMessage(const char* file, int line, LogSeverity severity, uint64 ctr,
void (LogMessage::*send_method)());

// Postpends ": strerror(errno) [errno]".
Expand Down