Hack together a clean build on Windows with MSVC
This commit is contained in:
parent
691f9256ce
commit
86a918e670
1 changed files with 8 additions and 0 deletions
|
@ -15,7 +15,11 @@
|
|||
#include <sys/types.h>
|
||||
#include <sys/stat.h>
|
||||
#include <fcntl.h>
|
||||
#ifndef _WIN32
|
||||
#include <unistd.h>
|
||||
#else
|
||||
#include <io.h>
|
||||
#endif
|
||||
#include <errno.h>
|
||||
|
||||
#include "bcrypt.h"
|
||||
|
@ -39,7 +43,11 @@ static int try_close(int fd)
|
|||
static int try_read(int fd, char *out, size_t count)
|
||||
{
|
||||
size_t total;
|
||||
#ifndef _WIN32
|
||||
ssize_t partial;
|
||||
#else
|
||||
int partial;
|
||||
#endif
|
||||
|
||||
total = 0;
|
||||
while (total < count)
|
||||
|
|
Loading…
Add table
Reference in a new issue