Eric Pouech : kernel32: Fixed regression with echoing input characters.

Alexandre Julliard julliard at winehq.org
Fri Nov 12 11:22:39 CST 2010


Module: wine
Branch: master
Commit: 7f043168c10cbd7b7a0e5e7e937e08a038e98df6
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=7f043168c10cbd7b7a0e5e7e937e08a038e98df6

Author: Eric Pouech <eric.pouech at orange.fr>
Date:   Thu Nov 11 22:30:11 2010 +0100

kernel32: Fixed regression with echoing input characters.

---

 dlls/kernel32/console.c |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/dlls/kernel32/console.c b/dlls/kernel32/console.c
index d49731f..c0af117 100644
--- a/dlls/kernel32/console.c
+++ b/dlls/kernel32/console.c
@@ -156,7 +156,8 @@ static int  get_console_bare_fd(HANDLE hin)
 {
     int         fd;
 
-    if (wine_server_handle_to_fd(hin, 0, &fd, NULL) == STATUS_SUCCESS)
+    if (wine_server_handle_to_fd(wine_server_ptr_handle(console_handle_unmap(hin)),
+                                 0, &fd, NULL) == STATUS_SUCCESS)
         return fd;
     return -1;
 }
@@ -1587,7 +1588,7 @@ BOOL WINAPI ReadConsoleW(HANDLE hConsoleInput, LPVOID lpBuffer,
 
     if (!GetConsoleMode(hConsoleInput, &mode))
         return FALSE;
-    if ((fd == get_console_bare_fd(hConsoleInput)) == -1)
+    if ((fd = get_console_bare_fd(hConsoleInput)) != -1)
     {
         close(fd);
         is_bare = TRUE;




More information about the wine-cvs mailing list