Skip to content
This repository has been archived by the owner on Apr 22, 2023. It is now read-only.

Commit

Permalink
Browse files Browse the repository at this point in the history
update libuv to 9a5c1bad90
  • Loading branch information
Igor Zinkovsky committed Feb 27, 2012
1 parent 4f8d732 commit 70a393e
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
8 changes: 7 additions & 1 deletion deps/uv/src/win/fs.c
Expand Up @@ -294,6 +294,7 @@ void fs__read(uv_fs_t* req, uv_file file, void *buf, size_t length,
OVERLAPPED overlapped, *overlapped_ptr;
LARGE_INTEGER offset_;
DWORD bytes;
DWORD error;

VERIFY_UV_FILE(file, req);

Expand Down Expand Up @@ -323,7 +324,12 @@ void fs__read(uv_fs_t* req, uv_file file, void *buf, size_t length,
if (ReadFile(handle, buf, length, &bytes, overlapped_ptr)) {
SET_REQ_RESULT(req, bytes);
} else {
SET_REQ_WIN32_ERROR(req, GetLastError());
error = GetLastError();
if (error == ERROR_HANDLE_EOF) {
SET_REQ_RESULT(req, bytes);
} else {
SET_REQ_WIN32_ERROR(req, error);
}
}
}

Expand Down
1 change: 1 addition & 0 deletions deps/uv/src/win/util.c
Expand Up @@ -253,6 +253,7 @@ void uv_filetime_to_time_t(FILETIME* file_time, time_t* stat_time) {
time.tm_hour = system_time.wHour;
time.tm_min = system_time.wMinute;
time.tm_sec = system_time.wSecond;
time.tm_isdst = -1;

*stat_time = mktime(&time);
} else {
Expand Down

0 comments on commit 70a393e

Please sign in to comment.