Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

fix win32 compile, fix BuildLogTest.WriteRead on 2nd run #340

Merged
merged 3 commits into from

3 participants

@sgraham

compile fixes, and BuildLogTest. ObsoleteOldVersion was causing a leaked file handle, which meant the the TearDown failed to unlink, which caused the next run test to fail.

@buildhive

Evan Martin » ninja #12 SUCCESS
This pull request looks good
(what's this?)

@sgraham

sorry, actually that test is still flaky on windows. trying to figure out why now.

@sgraham

Annoying Windows file-locking actually found a (minor) bug!

@buildhive

Evan Martin » ninja #13 SUCCESS
This pull request looks good
(what's this?)

@buildhive

Evan Martin » ninja #14 SUCCESS
This pull request looks good
(what's this?)

@martine martine merged commit 039b662 into martine:master
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
This page is out of date. Refresh to see the latest.
Showing with 5 additions and 2 deletions.
  1. +2 −2 configure.py
  2. +1 −0  src/build_log.cc
  3. +2 −0  src/win32port.h
View
4 configure.py
@@ -150,8 +150,8 @@ def binary(name):
def shell_escape(str):
"""Escape str such that it's interpreted as a single argument by the shell."""
# This isn't complete, but it's just enough to make NINJA_PYTHON work.
- # TODO: do the appropriate thing for Windows-style cmd here, perhaps by
- # just returning the input string.
+ if platform == 'windows':
+ return str
if '"' in str:
return "'%s'" % str.replace("'", "\\'")
return str
View
1  src/build_log.cc
@@ -235,6 +235,7 @@ bool BuildLog::Load(const string& path, string* err) {
if (log_version < kOldestSupportedVersion) {
*err = "unable to extract version from build log, perhaps due to "
"being too old; you must clobber your build output and rebuild";
+ fclose(file);
return false;
}
}
View
2  src/win32port.h
@@ -16,6 +16,8 @@
#define NINJA_WIN32PORT_H_
#pragma once
+typedef signed short int16_t;
+typedef unsigned short uint16_t;
/// A 64-bit integer type
typedef signed long long int64_t;
typedef unsigned long long uint64_t;
Something went wrong with that request. Please try again.