Changeset 9582 for trunk/src


Ignore:
Timestamp:
Jan 2, 2003, 12:50:46 PM (23 years ago)
Author:
sandervl
Message:

Set the codepage of the message queue for each new thread that is created. (done for the main thread in user32)

Location:
trunk/src/kernel32
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/kernel32/oslibmisc.cpp

    r6500 r9582  
    1 /* $Id: oslibmisc.cpp,v 1.13 2001-08-09 08:45:06 sandervl Exp $ */
     1/* $Id: oslibmisc.cpp,v 1.14 2003-01-02 11:50:46 sandervl Exp $ */
    22/*
    33 * Misc OS/2 util. procedures
     
    271271//******************************************************************************
    272272//******************************************************************************
     273ULONG OSLibWinSetCp(ULONG hmq, ULONG codepage)
     274{
     275  return WinSetCp(hmq, codepage);
     276}
     277//******************************************************************************
     278//******************************************************************************
    273279ULONG OSLibQueryCountry()
    274280{
  • trunk/src/kernel32/oslibmisc.h

    r7963 r9582  
    1 /* $Id: oslibmisc.h,v 1.9 2002-02-19 13:08:19 sandervl Exp $ */
     1/* $Id: oslibmisc.h,v 1.10 2003-01-02 11:50:46 sandervl Exp $ */
    22/*
    33 * Misc util. procedures
     
    4444ULONG OSLibWinInitialize();
    4545ULONG OSLibWinQueryMsgQueue(ULONG hab);
     46ULONG OSLibWinSetCp(ULONG hmq, ULONG codepage);
    4647
    4748//#define CTRY_NONE                        0
  • trunk/src/kernel32/thread.cpp

    r8648 r9582  
    1 /* $Id: thread.cpp,v 1.46 2002-06-11 16:36:54 sandervl Exp $ */
     1/* $Id: thread.cpp,v 1.47 2003-01-02 11:50:46 sandervl Exp $ */
    22
    33/*
     
    3333#include "oslibdos.h"
    3434#include <handlemanager.h>
     35#include <codepage.h>
    3536
    3637#define DBG_LOCALLOG    DBG_thread
     
    101102//******************************************************************************
    102103#define MAX_CALLSTACK_SIZE 128
     104#ifdef DEBUG
     105static char *pszLastCaller = NULL;
     106#endif
    103107//******************************************************************************
    104108void WIN32API dbg_ThreadPushCall(char *pszCaller)
     
    112116    return;
    113117   
    114   teb->o.odin.dbgCallDepth++;
    115  
    116118  // add caller name to call stack trace
    117119  int iIndex = teb->o.odin.dbgCallDepth;
     
    124126  if (iIndex < MAX_CALLSTACK_SIZE)
    125127    teb->o.odin.arrstrCallStack[iIndex] = (PVOID)pszCaller;
     128
     129  teb->o.odin.dbgCallDepth++;
     130
     131  pszLastCaller = pszCaller;
    126132#endif
    127133}
     
    305311    winteb->o.odin.hab = OSLibWinInitialize();
    306312    winteb->o.odin.hmq = OSLibWinQueryMsgQueue(winteb->o.odin.hab);
     313    rc = OSLibWinSetCp(winteb->o.odin.hmq, GetDisplayCodepage());
     314    dprintf(("WinSetCP was %sOK", rc ? "" : "not "));
     315
    307316    dprintf(("Win32ThreadProc: hab %x hmq %x", winteb->o.odin.hab, winteb->o.odin.hmq));
    308317    dprintf(("Stack top 0x%x, stack end 0x%x", winteb->stack_top, winteb->stack_low));
Note: See TracChangeset for help on using the changeset viewer.