Commit 6b6dc42d authored by Iván Matellanes's avatar Iván Matellanes Committed by Alexandre Julliard

msvcirt: Add implementation of streambuf::seekoff/seekpos.

parent 1f1cf8a6
...@@ -354,9 +354,10 @@ int __thiscall streambuf_pbackfail(streambuf *this, int c) ...@@ -354,9 +354,10 @@ int __thiscall streambuf_pbackfail(streambuf *this, int c)
/* ?seekoff@streambuf@@UAEJJW4seek_dir@ios@@H@Z */ /* ?seekoff@streambuf@@UAEJJW4seek_dir@ios@@H@Z */
/* ?seekoff@streambuf@@UEAAJJW4seek_dir@ios@@H@Z */ /* ?seekoff@streambuf@@UEAAJJW4seek_dir@ios@@H@Z */
DEFINE_THISCALL_WRAPPER(streambuf_seekoff, 16) DEFINE_THISCALL_WRAPPER(streambuf_seekoff, 16)
streampos __thiscall streambuf_seekoff(streambuf *this, streamoff offset, int dir, int mode) #define call_streambuf_seekoff(this, off, dir, mode) CALL_VTBL_FUNC(this, 12, streampos, (streambuf*, streamoff, ios_seek_dir, int), (this, off, dir, mode))
streampos __thiscall streambuf_seekoff(streambuf *this, streamoff offset, ios_seek_dir dir, int mode)
{ {
FIXME("(%p %d %d %d): stub\n", this, offset, dir, mode); TRACE("(%p %d %d %d)\n", this, offset, dir, mode);
return EOF; return EOF;
} }
...@@ -365,8 +366,8 @@ streampos __thiscall streambuf_seekoff(streambuf *this, streamoff offset, int di ...@@ -365,8 +366,8 @@ streampos __thiscall streambuf_seekoff(streambuf *this, streamoff offset, int di
DEFINE_THISCALL_WRAPPER(streambuf_seekpos, 12) DEFINE_THISCALL_WRAPPER(streambuf_seekpos, 12)
streampos __thiscall streambuf_seekpos(streambuf *this, streampos pos, int mode) streampos __thiscall streambuf_seekpos(streambuf *this, streampos pos, int mode)
{ {
FIXME("(%p %d %d): stub\n", this, pos, mode); TRACE("(%p %d %d)\n", this, pos, mode);
return EOF; return call_streambuf_seekoff(this, pos, SEEKDIR_beg, mode);
} }
/* ?setb@streambuf@@IAEXPAD0H@Z */ /* ?setb@streambuf@@IAEXPAD0H@Z */
......
...@@ -23,6 +23,12 @@ ...@@ -23,6 +23,12 @@
typedef LONG streamoff; typedef LONG streamoff;
typedef LONG streampos; typedef LONG streampos;
typedef enum {
SEEKDIR_beg = 0,
SEEKDIR_cur = 1,
SEEKDIR_end = 2
} ios_seek_dir;
extern void* (__cdecl *MSVCRT_operator_new)(SIZE_T); extern void* (__cdecl *MSVCRT_operator_new)(SIZE_T);
extern void (__cdecl *MSVCRT_operator_delete)(void*); extern void (__cdecl *MSVCRT_operator_delete)(void*);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment