X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=src%2Flogging.cc;h=5543e3af494286a0288f13e9c55f7ec98afd2da5;hb=66088e4787e79676df4f1a90b19172f06d0904f3;hp=81d966fe5dd609719342416728035fce8091e42b;hpb=a0073e504be20faa7e9c3b31ba795bdcfb99c967;p=platform%2Fupstream%2Fglog.git diff --git a/src/logging.cc b/src/logging.cc index 81d966f..5543e3a 100644 --- a/src/logging.cc +++ b/src/logging.cc @@ -31,6 +31,7 @@ #include "utilities.h" +#include #include #include #include @@ -180,6 +181,10 @@ GLOG_DEFINE_string(log_backtrace_at, "", #define PATH_SEPARATOR '/' #ifndef HAVE_PREAD +#if defined(OS_WINDOWS) +#include +#define ssize_t SSIZE_T +#endif static ssize_t pread(int fd, void* buf, size_t count, off_t offset) { off_t orig_offset = lseek(fd, 0, SEEK_CUR); if (orig_offset == (off_t)-1) @@ -248,6 +253,7 @@ static bool TerminalSupportsColor() { !strcmp(term, "xterm") || !strcmp(term, "xterm-color") || !strcmp(term, "xterm-256color") || + !strcmp(term, "screen-256color") || !strcmp(term, "screen") || !strcmp(term, "linux") || !strcmp(term, "cygwin"); @@ -1454,7 +1460,7 @@ static void logging_fail() { #if defined(_DEBUG) && defined(_MSC_VER) // When debugging on windows, avoid the obnoxious dialog and make // it possible to continue past a LOG(FATAL) in the debugger - _asm int 3 + __debugbreak(); #else abort(); #endif