Ignore:
Timestamp:
Jul 3, 2000, 2:12:38 PM (25 years ago)
Author:
bird
Message:

Moved OutputDebugString to debug.cpp.

File:
1 edited

Legend:

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

    r3793 r3794  
    1 /* $Id: debug.cpp,v 1.3 2000-07-03 11:20:52 bird Exp $ */
     1/* $Id: debug.cpp,v 1.4 2000-07-03 12:12:38 bird Exp $ */
    22
    33/*
     
    8686 *              being debugged, so that it can change behaviour and for example
    8787 *              provide more debug information using functions like OutputDebugString.
     88 *
     89 *              You could change the result of this by SET ODIN32.DEBUGGERPRESENT=1 on
     90 *              the commandline.
    8891 */
    8992BOOL WIN32API IsDebuggerPresent(VOID)
    9093{
    9194    dprintf(("KERNEL32:  IsDebuggerPresent() -> FALSE\n"));
    92     return FALSE;
     95    return (getenv("ODIN32.DEBUGGERPRESENT") != NULL);
    9396}
     97
     98
     99/**
     100 * Send a string to the debugger for the current application.
     101 * @param       lpszOutputString    Pointer to the string to send to the debugger. (intput)
     102 * @sketch      Convert and log the string.
     103 * @status      STUB
     104 * @author      Sander van Leeuwen
     105 * @remark      The string is send to the system debugger if there is no
     106 *              debugger available for this application.
     107 *              If the application has not debugger and the system debugger
     108 *              is not active this API does nothing.
     109 */
     110VOID WIN32API OutputDebugStringW(LPCWSTR lpszOutputString)
     111{
     112    char    *pszAscii = UnicodeToAsciiString((LPWSTR)lpszOutputString);
     113    dprintf(("KERNEL32:  OS2OutputDebugStringW %s\n", pszAscii));
     114    FreeAsciiString(pszAscii);
     115}
     116
     117
     118/**
     119 * Send a string to the debugger for the current application.
     120 * @param       lpszOutputString    Pointer to the string to send to the debugger. (input)
     121 * @sketch      Log the string.
     122 * @status      STUB
     123 * @author      Sander van Leeuwen
     124 * @remark      The string is send to the system debugger if there is no
     125 *              debugger available for this application.
     126 *              If the application has not debugger and the system debugger
     127 *              is not active this API does nothing.
     128 */
     129VOID WIN32API OutputDebugStringA(LPCSTR lpszOutputString)
     130{
     131    dprintf(("KERNEL32:  OutputDebugStringA: %s\n", lpszOutputString));
     132}
     133
Note: See TracChangeset for help on using the changeset viewer.