Implemented _read and _lseek.
This commit is contained in:
parent
7be99b015c
commit
78f92898a4
|
@ -181,7 +181,7 @@ init CRTDLL_Init
|
|||
@ cdecl _lrotl (long long) CRTDLL__lrotl
|
||||
@ stub _lrotr
|
||||
@ stub _lsearch
|
||||
@ stub _lseek
|
||||
@ cdecl _lseek(long long long) CRTDLL__lseek
|
||||
@ cdecl _ltoa(long str long) CRTDLL__ltoa
|
||||
@ stub _ltow
|
||||
@ cdecl _makepath (ptr str str str str) CRTDLL__makepath
|
||||
|
|
|
@ -332,18 +332,6 @@ INT __cdecl CRTDLL__setjmp(LPDWORD *jmpbuf)
|
|||
FIXME(":(%p): stub\n",jmpbuf);
|
||||
return 0;
|
||||
}
|
||||
/*********************************************************************
|
||||
* _read (CRTDLL.256)
|
||||
*
|
||||
* BUGS
|
||||
* Unimplemented
|
||||
*/
|
||||
INT __cdecl CRTDLL__read(INT fd, LPVOID buf, UINT count)
|
||||
{
|
||||
FIXME(":(%d,%p,%d): stub\n",fd,buf,count);
|
||||
SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
/*********************************************************************
|
||||
* fopen (CRTDLL.372)
|
||||
|
@ -476,6 +464,18 @@ INT __cdecl CRTDLL_fscanf( CRTDLL_FILE *stream, LPSTR format, ... )
|
|||
return 0;
|
||||
}
|
||||
|
||||
/*********************************************************************
|
||||
* _lseek (CRTDLL.179)
|
||||
*/
|
||||
LONG __cdecl CRTDLL__lseek( INT fd, LONG offset, INT whence)
|
||||
{
|
||||
TRACE("fd %d to 0x%08lx pos %s\n",
|
||||
fd,offset,(whence==SEEK_SET)?"SEEK_SET":
|
||||
(whence==SEEK_CUR)?"SEEK_CUR":
|
||||
(whence==SEEK_END)?"SEEK_END":"UNKNOWN");
|
||||
return SetFilePointer( fd, offset, NULL, whence );
|
||||
}
|
||||
|
||||
/*********************************************************************
|
||||
* fseek (CRTDLL.382)
|
||||
*/
|
||||
|
@ -640,6 +640,17 @@ BOOL __cdecl CRTDLL__isatty(DWORD x)
|
|||
return TRUE;
|
||||
}
|
||||
|
||||
/*********************************************************************
|
||||
* _read (CRTDLL.256)
|
||||
*
|
||||
*/
|
||||
INT __cdecl CRTDLL__read(INT fd, LPVOID buf, UINT count)
|
||||
{
|
||||
TRACE("0x%08x bytes fd %d to %p\n", count,fd,buf);
|
||||
if (!fd) fd = GetStdHandle( STD_INPUT_HANDLE );
|
||||
return _lread( fd, buf, count );
|
||||
}
|
||||
|
||||
/*********************************************************************
|
||||
* _write (CRTDLL.332)
|
||||
*/
|
||||
|
@ -1219,6 +1230,8 @@ HFILE __cdecl CRTDLL__open(LPCSTR path,INT flags)
|
|||
}
|
||||
if (flags & 0x0008) /* O_APPEND */
|
||||
FIXME("O_APPEND not supported\n" );
|
||||
if (!(flags & 0x8000 /* O_BINARY */ ) || (flags & 0x4000 /* O_TEXT */))
|
||||
FIXME(":text mode not supported\n");
|
||||
if (flags & 0xf0f4)
|
||||
TRACE("CRTDLL_open file unsupported flags 0x%04x\n",flags);
|
||||
/* End Fixme */
|
||||
|
|
Loading…
Reference in New Issue