Michael Stefaniuc : winedbg: Fix the return type of read_input(); it is never negative.

Alexandre Julliard julliard at winehq.org
Tue Aug 20 14:38:37 CDT 2013


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

Author: Michael Stefaniuc <mstefani at redhat.de>
Date:   Tue Aug 20 00:13:42 2013 +0200

winedbg: Fix the return type of read_input(); it is never negative.

---

 programs/winedbg/debug.l |    5 ++---
 1 files changed, 2 insertions(+), 3 deletions(-)

diff --git a/programs/winedbg/debug.l b/programs/winedbg/debug.l
index a6ab10c..ef7a2eb 100644
--- a/programs/winedbg/debug.l
+++ b/programs/winedbg/debug.l
@@ -61,7 +61,7 @@ void lexeme_flush(void)
     next_lexeme = 0;
 }
 
-static int read_input(const char* pfx, char* buf, int size)
+static size_t read_input(const char* pfx, char* buf, int size)
 {
     int len;
     static char*  last_line = NULL;
@@ -107,8 +107,7 @@ static int read_input(const char* pfx, char* buf, int size)
 }
 
 #define YY_INPUT(buf,result,max_size) \
-	if ((result = read_input("Wine-dbg>", buf, max_size)) < 0) \
-	    YY_FATAL_ERROR("read_input in flex scanner failed");
+        (result = read_input("Wine-dbg>", buf, max_size))
 
 static int syntax_error;
 %}




More information about the wine-cvs mailing list