Skip to content

Instantly share code, notes, and snippets.

@igorzi
Created November 17, 2011 23:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save igorzi/1374904 to your computer and use it in GitHub Desktop.
Save igorzi/1374904 to your computer and use it in GitHub Desktop.
From b0b54bf88dca19cdc0a6cffaba93c2073dbdb0f4 Mon Sep 17 00:00:00 2001
From: Igor Zinkovsky <igorzi@microsoft.com>
Date: Thu, 17 Nov 2011 15:18:32 -0800
Subject: [PATCH] windows: return UV_FILE for non-console FILE_TYPE_CHAR
---
src/win/handle.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/src/win/handle.c b/src/win/handle.c
index b67139c..ba0af75 100644
--- a/src/win/handle.c
+++ b/src/win/handle.c
@@ -35,7 +35,7 @@ uv_handle_type uv_guess_handle(uv_file file) {
if (GetConsoleMode(handle, &mode)) {
return UV_TTY;
} else {
- return UV_UNKNOWN_HANDLE;
+ return UV_FILE;
}
case FILE_TYPE_PIPE:
--
1.7.4.msysgit.0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment