Skip to content

Commit dd6faa5

Browse files
committed
uv: upgrade to 179f475
1 parent ac379b3 commit dd6faa5

File tree

5 files changed

+10
-3
lines changed

5 files changed

+10
-3
lines changed

deps/uv/src/win/fs.c

+2-2
Original file line numberDiff line numberDiff line change
@@ -424,7 +424,7 @@ void fs__readdir(uv_fs_t* req, const wchar_t* path, int flags) {
424424
len = wcslen(name);
425425

426426
if (!buf) {
427-
buf = (wchar_t*)malloc(buf_size);
427+
buf = (wchar_t*)malloc(buf_size * sizeof(wchar_t));
428428
if (!buf) {
429429
uv_fatal_error(ERROR_OUTOFMEMORY, "malloc");
430430
}
@@ -435,7 +435,7 @@ void fs__readdir(uv_fs_t* req, const wchar_t* path, int flags) {
435435
while ((ptr - buf) + len + 1 > buf_size) {
436436
buf_size *= 2;
437437
path2 = buf;
438-
buf = (wchar_t*)realloc(buf, buf_size);
438+
buf = (wchar_t*)realloc(buf, buf_size * sizeof(wchar_t));
439439
if (!buf) {
440440
uv_fatal_error(ERROR_OUTOFMEMORY, "realloc");
441441
}

deps/uv/src/win/tcp.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -964,7 +964,7 @@ int uv_tcp_nodelay(uv_tcp_t* handle, int enable) {
964964
}
965965

966966

967-
int uv_tcp_keepalive(uv_tcp_t* handle, int enable, int delay) {
967+
int uv_tcp_keepalive(uv_tcp_t* handle, int enable, unsigned int delay) {
968968
uv__set_artificial_error(handle->loop, UV_ENOSYS);
969969
return -1;
970970
}

deps/uv/src/win/tty.c

+1
Original file line numberDiff line numberDiff line change
@@ -1334,6 +1334,7 @@ static int uv_tty_write_bufs(uv_tty_t* handle, uv_buf_t bufs[], int bufcnt,
13341334

13351335
case 'c':
13361336
/* Full console reset. */
1337+
FLUSH_TEXT();
13371338
uv_tty_reset(handle, error);
13381339
ansi_parser_state = ANSI_NORMAL;
13391340
continue;

deps/uv/src/win/winapi.h

+4
Original file line numberDiff line numberDiff line change
@@ -4211,6 +4211,10 @@ typedef enum _FILE_INFORMATION_CLASS {
42114211
# define FILE_DEVICE_FILE_SYSTEM 0x00000009
42124212
#endif
42134213

4214+
#ifndef FILE_DEVICE_NETWORK
4215+
# define FILE_DEVICE_NETWORK 0x00000012
4216+
#endif
4217+
42144218
#ifndef METHOD_BUFFERED
42154219
# define METHOD_BUFFERED 0
42164220
#endif

deps/uv/src/win/winsock.h

+2
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,8 @@
2727
#include <ws2tcpip.h>
2828
#include <windows.h>
2929

30+
#include "winapi.h"
31+
3032

3133
/*
3234
* MinGW is missing these too

0 commit comments

Comments
 (0)