[freedos-32-commit] drivers/keyb/src init.c,1.8,1.9
Status: Pre-Alpha
Brought to you by:
salvois
From: Salvatore I. <sa...@us...> - 2005-05-14 20:41:13
|
Update of /cvsroot/freedos-32/drivers/keyb/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv8082/src Modified Files: init.c Log Message: Using standard error codes, changed all around the world. Some fresh air to the DPMI driver. Index: init.c =================================================================== RCS file: /cvsroot/freedos-32/drivers/keyb/src/init.c,v retrieving revision 1.8 retrieving revision 1.9 diff -u -d -r1.8 -r1.9 --- init.c 3 Apr 2005 00:47:22 -0000 1.8 +++ init.c 14 May 2005 20:41:04 -0000 1.9 @@ -7,7 +7,7 @@ */ #include <dr-env.h> -#include <errors.h> +#include <errno.h> #include <devices.h> #include "key.h" @@ -53,7 +53,7 @@ */ static int read(void *id, DWORD n, BYTE *buf) { - int res = FD32_EREAD; + int res = -EIO; DWORD count; /* Convention: n = 0 --> nonblock; n != 0 --> block */ @@ -112,13 +112,13 @@ break; case FD32_READ: if (r->Size < sizeof(fd32_read_t)) { - res = FD32_EFORMAT; + res = -EINVAL; } else { res = read(r->DeviceId, r->BufferBytes, r->Buffer); } break; default: - res = FD32_EINVAL; + res = -ENOTSUP; break; } |