Ignore:
Timestamp:
Jan 29, 2001, 2:21:28 AM (25 years ago)
Author:
bird
Message:

Corrected bogus syntax. (strict compiler) Removed EXPORT keywords.

File:
1 edited

Legend:

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

    r4658 r5036  
    1 /* $Id: misc.cpp,v 1.28 2000-11-21 11:35:08 sandervl Exp $ */
     1/* $Id: misc.cpp,v 1.29 2001-01-29 01:21:28 bird Exp $ */
    22
    33/*
     
    8383/* arguments.                                                        */
    8484/* ----------------------------------------------------------------- */
    85 int SYSTEM EXPORT WriteLog(char *f, ...)
     85int SYSTEM WriteLog(char *f, ...)
    8686  {
    8787  TIB    *ptib;                    /* process/thread id structures */
     
    257257#endif
    258258
    259 int SYSTEM EXPORT WriteLog(char *tekst, ...)
     259int SYSTEM WriteLog(char *tekst, ...)
    260260{
    261261  USHORT  sel = RestoreOS2FS();
     
    311311//******************************************************************************
    312312//******************************************************************************
    313 int SYSTEM EXPORT WriteLogNoEOL(char *tekst, ...)
     313int SYSTEM WriteLogNoEOL(char *tekst, ...)
    314314{
    315315  USHORT  sel = RestoreOS2FS();
     
    369369//******************************************************************************
    370370//******************************************************************************
    371 int SYSTEM EXPORT WritePrivateLog(void *logfile, char *tekst, ...)
     371int SYSTEM WritePrivateLog(void *logfile, char *tekst, ...)
    372372{
    373373  USHORT  sel = RestoreOS2FS();
     
    400400void LogException(int state)
    401401{
    402   TEB *teb = GetThreadTEB();
    403   USHORT *lock;
    404 
    405   if(!teb) return;
    406 
    407   if(teb->o.odin.logfile) {
    408     if(state == ENTER_EXCEPTION) {
     402    TEB *teb = GetThreadTEB();
     403
     404    if (!teb) return;
     405
     406#if !defined(__EMX__)
     407    if (teb->o.odin.logfile)
     408    {
    409409#if (__IBMCPP__ == 300) || (__IBMC__ == 300)
    410         lock = (USHORT *)(teb->o.odin.logfile+0x1C);
     410        PUSHORT lock = (USHORT *)(teb->o.odin.logfile+0x1C);
    411411#else
    412412#error Check the offset of the lock count word in the file stream structure for this compiler revision!!!!!
    413413#endif
    414         (*lock)--;
    415     }
    416     else { //LEAVE_EXCEPTION
    417 #if (__IBMCPP__ == 300) || (__IBMC__ == 300)
    418         lock = (USHORT *)(teb->o.odin.logfile+0x1C);
    419 #else
    420 #error Check the offset of the lock count word in the file stream structure for this compiler revision!!!!!
    421 #endif
    422         (*lock)++;
    423     }
    424   }
     414        if (state == ENTER_EXCEPTION)
     415        {
     416            (*lock)--;
     417        }
     418        else
     419        { //LEAVE_EXCEPTION
     420            (*lock)++;
     421        }
     422    }
     423#else
     424//kso 2001-01-29: EMX/GCC
     425// we maybe should do something with the _more->rsem (_rmutex) structure but
     426// I wanna have this compile, so we'll address problems later.
     427#endif
    425428}
    426429//******************************************************************************
     
    432435{
    433436  TEB *teb = GetThreadTEB();
    434   USHORT *lock;
     437  PUSHORT lock;
    435438
    436439  if(!teb) return;
    437440
     441#if !defined(__EMX__)
    438442  if(teb->o.odin.logfile) {
    439443    //oops, exception in vfprintf; let's clear the lock count
    440444#if (__IBMCPP__ == 300) || (__IBMC__ == 300)
    441     lock = (USHORT *)(teb->o.odin.logfile+0x1C);
     445    lock = (PUSHORT)(teb->o.odin.logfile+0x1C);
    442446#else
    443447#error Check the offset of the lock count word in the file stream structure for this compiler revision!!!!!
     
    445449    (*lock)--;
    446450  }
     451#else
     452//kso 2001-01-29: EMX/GCC
     453// we maybe should do something with the _more->rsem (_rmutex) structure but
     454// I wanna have this compile, so we'll address problems later.
     455#endif
    447456}
    448457//******************************************************************************
     
    486495//******************************************************************************
    487496//******************************************************************************
    488 int SYSTEM EXPORT WriteLogError(char *tekst, ...)
     497int SYSTEM WriteLogError(char *tekst, ...)
    489498{
    490499  USHORT  sel = RestoreOS2FS();
     
    568577 *****************************************************************************/
    569578
    570 int SYSTEM EXPORT DebugErrorBox(ULONG  iErrorCode,
    571                                 char*  pszFormat,
    572                                 ...)
     579int SYSTEM DebugErrorBox(ULONG  iErrorCode,
     580                         char*  pszFormat,
     581                         ...)
    573582{
    574583  char   szMessageBuffer[1024];              /* buffer for the text message */
Note: See TracChangeset for help on using the changeset viewer.