summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
author <shinichiro.hamaji@gmail.com>2014-08-19 00:36:29 (GMT)
committer <shinichiro.hamaji@gmail.com>2014-08-19 00:36:29 (GMT)
commit78da3bf8fec7efbe046547ae00cdeafdb9a85a6d (patch)
tree18038d1f5397b36d7180d04b209c23c7c88ed263 /src
parent09e8dd6289f5e02c183af6f91e8646f27ccdba40 (diff)
downloadglog-78da3bf8fec7efbe046547ae00cdeafdb9a85a6d.zip
glog-78da3bf8fec7efbe046547ae00cdeafdb9a85a6d.tar.gz
glog-78da3bf8fec7efbe046547ae00cdeafdb9a85a6d.tar.bz2
Fixes for the latest MSVS.
- ssize_t Since Windows does not have ssize_t, we need to include BaseTsd.h and use SSIZE_t instead. - include algorithm MSVS 2013 requests developers to include algorithm when they use std::min. By yyanagisawa git-svn-id: https://google-glog.googlecode.com/svn/trunk@143 eb4d4688-79bd-11dd-afb4-1d65580434c0
Diffstat (limited to 'src')
-rw-r--r--src/logging.cc5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/logging.cc b/src/logging.cc
index 81d966f..f1f519a 100644
--- a/src/logging.cc
+++ b/src/logging.cc
@@ -31,6 +31,7 @@
#include "utilities.h"
+#include <algorithm>
#include <assert.h>
#include <iomanip>
#include <string>
@@ -180,6 +181,10 @@ GLOG_DEFINE_string(log_backtrace_at, "",
#define PATH_SEPARATOR '/'
#ifndef HAVE_PREAD
+#if defined(OS_WINDOWS)
+#include <BaseTsd.h>
+#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)