Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
mpd
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
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Иван Мажукин
mpd
Commits
cd776ff1
Commit
cd776ff1
authored
Mar 03, 2015
by
Max Kellermann
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
system/FileDescriptor: fix WIN32 checks
parent
40a587bb
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
5 deletions
+5
-5
FileDescriptor.cxx
src/system/FileDescriptor.cxx
+3
-3
FileDescriptor.hxx
src/system/FileDescriptor.hxx
+2
-2
No files found.
src/system/FileDescriptor.cxx
View file @
cd776ff1
...
...
@@ -33,7 +33,7 @@
#include <sys/stat.h>
#include <fcntl.h>
#if
def HAVE_POSIX
#if
ndef WIN32
#include <poll.h>
#endif
...
...
@@ -72,7 +72,7 @@ FileDescriptor::OpenReadOnly(const char *pathname)
return
Open
(
pathname
,
O_RDONLY
|
O_NOCTTY
|
O_CLOEXEC
);
}
#if
def HAVE_POSIX
#if
ndef WIN32
bool
FileDescriptor
::
OpenNonBlocking
(
const
char
*
pathname
)
...
...
@@ -188,7 +188,7 @@ FileDescriptor::GetSize() const
:
-
1
;
}
#if
def HAVE_POSIX
#if
ndef WIN32
int
FileDescriptor
::
Poll
(
short
events
,
int
timeout
)
const
...
...
src/system/FileDescriptor.hxx
View file @
cd776ff1
...
...
@@ -93,7 +93,7 @@ public:
bool
Open
(
const
char
*
pathname
,
int
flags
);
bool
OpenReadOnly
(
const
char
*
pathname
);
#if
def HAVE_POSIX
#if
ndef WIN32
bool
OpenNonBlocking
(
const
char
*
pathname
);
static
bool
CreatePipe
(
FileDescriptor
&
r
,
FileDescriptor
&
w
);
...
...
@@ -160,7 +160,7 @@ public:
return
::
write
(
fd
,
buffer
,
length
);
}
#if
def HAVE_POSIX
#if
ndef WIN32
int
Poll
(
short
events
,
int
timeout
)
const
;
int
WaitReadable
(
int
timeout
)
const
;
...
...
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