branch update for HEAD-2003021201
[reactos.git] / lib / crtdll / stdio / getc.c
index fe87af3..0983fc3 100644 (file)
@@ -1,8 +1,8 @@
 #include <windows.h>
-#include <crtdll/stdio.h>
-#include <crtdll/wchar.h>
-#include <crtdll/errno.h>
-#include <crtdll/internal/file.h>
+#include <msvcrt/stdio.h>
+#include <msvcrt/wchar.h>
+#include <msvcrt/errno.h>
+#include <msvcrt/internal/file.h>
 
 //getc can be a macro
 #undef getc
@@ -25,7 +25,7 @@ int getc(FILE *fp)
 
        if(fp->_cnt > 0) {
                fp->_cnt--;
-               c =  (int)*fp->_ptr++;
+               c =  (int)(*fp->_ptr++ & 0377);
        } 
        else {
                c =  _filbuf(fp);