Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
C
capnproto
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
capnproto
Commits
ad87e243
Unverified
Commit
ad87e243
authored
Mar 21, 2019
by
Kenton Varda
Committed by
GitHub
Mar 21, 2019
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #809 from capnproto/jlee/fix-mingw-warnings
Jlee/fix mingw warnings
parents
f35bd896
ba5e63b3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
11 additions
and
19 deletions
+11
-19
async-io-win32.c++
c++/src/kj/async-io-win32.c++
+0
-11
exception-test.c++
c++/src/kj/exception-test.c++
+4
-2
filesystem-disk-win32.c++
c++/src/kj/filesystem-disk-win32.c++
+7
-6
No files found.
c++/src/kj/async-io-win32.c++
View file @
ad87e243
...
...
@@ -189,17 +189,6 @@ int win32Socketpair(SOCKET socks[2]) {
namespace
{
bool
detectWine
()
{
HMODULE
hntdll
=
GetModuleHandle
(
"ntdll.dll"
);
if
(
hntdll
==
NULL
)
return
false
;
return
GetProcAddress
(
hntdll
,
"wine_get_version"
)
!=
nullptr
;
}
bool
isWine
()
{
static
bool
result
=
detectWine
();
return
result
;
}
// =======================================================================================
static
constexpr
uint
NEW_FD_FLAGS
=
LowLevelAsyncIoProvider
::
TAKE_OWNERSHIP
;
...
...
c++/src/kj/exception-test.c++
View file @
ad87e243
...
...
@@ -30,9 +30,11 @@ namespace {
TEST
(
Exception
,
TrimSourceFilename
)
{
#if _WIN32
if
(
trimSourceFilename
(
__FILE__
)
!=
"kj
\\
exception-test.c++"
)
#endif
EXPECT_TRUE
(
trimSourceFilename
(
__FILE__
)
==
"kj/exception-test.c++"
||
trimSourceFilename
(
__FILE__
)
==
"kj
\\
exception-test.c++"
);
#else
EXPECT_EQ
(
trimSourceFilename
(
__FILE__
),
"kj/exception-test.c++"
);
#endif
}
TEST
(
Exception
,
RunCatchingExceptions
)
{
...
...
c++/src/kj/filesystem-disk-win32.c++
View file @
ad87e243
...
...
@@ -22,6 +22,12 @@
#if _WIN32
// For Unix implementation, see filesystem-disk-unix.c++.
// Request Vista-level APIs.
#define WINVER 0x0600
#define _WIN32_WINNT 0x0600
#define WIN32_LEAN_AND_MEAN // ::eyeroll::
#include "filesystem.h"
#include "debug.h"
#include "encoding.h"
...
...
@@ -29,12 +35,6 @@
#include <algorithm>
#include <wchar.h>
// Request Vista-level APIs.
#define WINVER 0x0600
#define _WIN32_WINNT 0x0600
#define WIN32_LEAN_AND_MEAN // ::eyeroll::
#include <windows.h>
#include <winioctl.h>
#include "windows-sanity.h"
...
...
@@ -869,6 +869,7 @@ public:
// Retry, but make sure we don't try to create the parent again.
return
tryReplaceNode
(
path
,
mode
-
WriteMode
::
CREATE_PARENT
,
kj
::
mv
(
tryCreate
));
}
// fallthrough
default
:
KJ_FAIL_WIN32
(
"create(path)"
,
error
,
path
)
{
return
false
;
}
}
else
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment