msvcp60: Remove mutex class.
This commit is contained in:
parent
4b7333e227
commit
b999c3e307
|
@ -1592,7 +1592,6 @@ static basic_streambuf_wchar* basic_streambuf_wchar_ctor_uninitialized(basic_str
|
|||
{
|
||||
TRACE("(%p %d)\n", this, uninitialized);
|
||||
this->vtable = &MSVCP_basic_streambuf_wchar_vtable;
|
||||
mutex_ctor(&this->lock);
|
||||
return this;
|
||||
}
|
||||
|
||||
|
@ -1614,7 +1613,6 @@ static basic_streambuf_wchar* basic_streambuf_wchar_ctor(basic_streambuf_wchar *
|
|||
TRACE("(%p)\n", this);
|
||||
|
||||
this->vtable = &MSVCP_basic_streambuf_wchar_vtable;
|
||||
mutex_ctor(&this->lock);
|
||||
locale_ctor(&this->loc);
|
||||
basic_streambuf_wchar__Init_empty(this);
|
||||
|
||||
|
@ -1641,7 +1639,6 @@ void __thiscall basic_streambuf_wchar_dtor(basic_streambuf_wchar *this)
|
|||
{
|
||||
TRACE("(%p)\n", this);
|
||||
|
||||
mutex_dtor(&this->lock);
|
||||
locale_dtor(&this->loc);
|
||||
}
|
||||
|
||||
|
@ -1736,7 +1733,6 @@ void __thiscall basic_streambuf_wchar__Init(basic_streambuf_wchar *this, wchar_t
|
|||
static void basic_streambuf_wchar__Lock(basic_streambuf_wchar *this)
|
||||
{
|
||||
TRACE("(%p)\n", this);
|
||||
mutex_lock(&this->lock);
|
||||
}
|
||||
|
||||
/* ?_Pnavail@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBEHXZ */
|
||||
|
@ -1847,7 +1843,6 @@ static streamsize basic_streambuf_wchar__Sgetn_s(basic_streambuf_wchar *this, wc
|
|||
static void basic_streambuf_wchar__Unlock(basic_streambuf_wchar *this)
|
||||
{
|
||||
TRACE("(%p)\n", this);
|
||||
mutex_unlock(&this->lock);
|
||||
}
|
||||
|
||||
/* ?eback@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBEPA_WXZ */
|
||||
|
|
|
@ -27,43 +27,6 @@
|
|||
#include "winbase.h"
|
||||
|
||||
|
||||
/* ??0_Mutex@std@@QAE@XZ */
|
||||
/* ??0_Mutex@std@@QEAA@XZ */
|
||||
mutex* mutex_ctor(mutex *this)
|
||||
{
|
||||
CRITICAL_SECTION *cs = MSVCRT_operator_new(sizeof(*cs));
|
||||
if(!cs)
|
||||
throw_exception(EXCEPTION_BAD_ALLOC, NULL);
|
||||
|
||||
InitializeCriticalSection(cs);
|
||||
cs->DebugInfo->Spare[0] = (DWORD_PTR)(__FILE__ ": _Mutex critical section");
|
||||
this->mutex = cs;
|
||||
return this;
|
||||
}
|
||||
|
||||
/* ??1_Mutex@std@@QAE@XZ */
|
||||
/* ??1_Mutex@std@@QEAA@XZ */
|
||||
void mutex_dtor(mutex *this)
|
||||
{
|
||||
((CRITICAL_SECTION*)this->mutex)->DebugInfo->Spare[0] = 0;
|
||||
DeleteCriticalSection(this->mutex);
|
||||
MSVCRT_operator_delete(this->mutex);
|
||||
}
|
||||
|
||||
/* ?_Lock@_Mutex@std@@QAEXXZ */
|
||||
/* ?_Lock@_Mutex@std@@QEAAXXZ */
|
||||
void mutex_lock(mutex *this)
|
||||
{
|
||||
EnterCriticalSection(this->mutex);
|
||||
}
|
||||
|
||||
/* ?_Unlock@_Mutex@std@@QAEXXZ */
|
||||
/* ?_Unlock@_Mutex@std@@QEAAXXZ */
|
||||
void mutex_unlock(mutex *this)
|
||||
{
|
||||
LeaveCriticalSection(this->mutex);
|
||||
}
|
||||
|
||||
static CRITICAL_SECTION lockit_cs;
|
||||
|
||||
void init_lockit(void) {
|
||||
|
|
|
@ -198,16 +198,6 @@ void free_lockit(void);
|
|||
_Lockit* __thiscall _Lockit_ctor_locktype(_Lockit*, int);
|
||||
void __thiscall _Lockit_dtor(_Lockit*);
|
||||
|
||||
/* class mutex */
|
||||
typedef struct {
|
||||
void *mutex;
|
||||
} mutex;
|
||||
|
||||
mutex* mutex_ctor(mutex*);
|
||||
void mutex_dtor(mutex*);
|
||||
void mutex_lock(mutex*);
|
||||
void mutex_unlock(mutex*);
|
||||
|
||||
typedef enum {
|
||||
FMTFLAG_skipws = 0x0001,
|
||||
FMTFLAG_unitbuf = 0x0002,
|
||||
|
@ -331,7 +321,6 @@ int __thiscall basic_streambuf_char_sputc(basic_streambuf_char*, char);
|
|||
/* class basic_streambuf<wchar> */
|
||||
typedef struct {
|
||||
const vtable_ptr *vtable;
|
||||
mutex lock;
|
||||
wchar_t *rbuf;
|
||||
wchar_t *wbuf;
|
||||
wchar_t **prbuf;
|
||||
|
|
Loading…
Reference in New Issue