Ignore:
Timestamp:
Dec 9, 2001, 5:00:30 PM (24 years ago)
Author:
bird
Message:

Removed 'typedef struct _HMDEVICE'; bogus code.

File:
1 edited

Legend:

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

    r7579 r7593  
    1 /* $Id: HandleManager.cpp,v 1.85 2001-12-08 15:12:15 sandervl Exp $ */
     1/* $Id: HandleManager.cpp,v 1.86 2001-12-09 16:00:30 bird Exp $ */
    22
    33/*
     
    8585 *****************************************************************************/
    8686
    87 typedef struct _HMDEVICE;
    88 
    8987typedef struct _HMHANDLE
    9088{
     
    265263        //SvL: Mark handle as allocated here. Doing it outside of this function
    266264        //     isn't thread safe. (and not very smart)
    267         TabWin32Handles[ulLoop].hmHandleData.hHMHandle      = ulLoop; 
     265        TabWin32Handles[ulLoop].hmHandleData.hHMHandle      = ulLoop;
    268266        TabWin32Handles[ulLoop].hmHandleData.dwUserData     = 0;
    269267        TabWin32Handles[ulLoop].hmHandleData.dwInternalType = HMTYPE_UNKNOWN;
     
    435433
    436434    HMGlobals.fIsInitialized = TRUE;                             /* OK, done */
    437    
     435
    438436#if 1
    439     //This is a very bad idea. \\\\.\\NTICE -> NTICE, if the file exits, then 
     437    //This is a very bad idea. \\\\.\\NTICE -> NTICE, if the file exits, then
    440438    //it will open the file instead of the device driver
    441439    /* add standard symbolic links first, so local symbolic links in the
     
    472470    }
    473471#endif
    474    
     472
    475473    /* copy standard handles from OS/2's Open32 Subsystem */
    476474    HMGlobals.pHMStandard   = new HMDeviceStandardClass("\\\\STANDARD_HANDLE\\");
     
    585583           hHandleOS2));
    586584#endif
    587  
     585
    588586  // @@@PH 2001-09-27
    589587  // prevent too quick re-use of last handle
     
    10361034      lpFileName = szFilename;
    10371035    }
    1038      
    1039    
     1036
     1037
    10401038    pDeviceHandler = _HMDeviceFind((LPSTR)lpFileName);        /* find device */
    10411039    if (NULL == pDeviceHandler)                /* this name is unknown to us */
     
    11031101  if (rc != NO_ERROR)     /* oops, creation failed within the device handler */
    11041102  {
    1105     TabWin32Handles[iIndexNew].hmHandleData.hHMHandle = INVALID_HANDLE_VALUE; 
    1106    
     1103    TabWin32Handles[iIndexNew].hmHandleData.hHMHandle = INVALID_HANDLE_VALUE;
     1104
    11071105    // Note:
    11081106    // device handlers have to return an Win32-style error code
     
    11741172  PHMHANDLEDATA   pHMHandleData;
    11751173  DWORD           rc;                                     /* API return code */
    1176  
     1174
    11771175  // name resolving
    11781176  CHAR szFilename[260];
     
    11851183    lpFileName = szFilename;
    11861184  }
    1187  
    1188  
     1185
     1186
    11891187  if(fuMode & OF_REOPEN) {
    11901188       pDeviceHandler = _HMDeviceFind((LPSTR)pOFStruct->szPathName);          /* find device */
     
    12031201  }
    12041202  else pDevData       = _HMDeviceGetData((LPSTR)lpFileName);
    1205  
     1203
    12061204
    12071205  if(pDeviceHandler == HMGlobals.pHMOpen32) {
     
    19181916          // processes messages while waiting for the process to die)
    19191917          //(Napster install now doesn't block PM anymore (forcing a reboot))
    1920  
     1918
    19211919          HMODULE hUser32 = LoadLibraryA("USER32.DLL");
    19221920
     
    19411939
    19421940          while(TRUE) {
    1943               dwResult = HMMsgWaitForMultipleObjects(1, &hObject, FALSE, 
     1941              dwResult = HMMsgWaitForMultipleObjects(1, &hObject, FALSE,
    19441942                                                     INFINITE, QS_ALLINPUT);
    19451943              if(dwResult == WAIT_OBJECT_0 + 1) {
    19461944                  MSG msg ;
    1947    
    1948                   while (pfnPeekMessageA(&msg, NULL, 0, 0, PM_REMOVE)) 
     1945
     1946                  while (pfnPeekMessageA(&msg, NULL, 0, 0, PM_REMOVE))
    19491947                  {
    19501948                     if (msg.message == WM_QUIT) {
     
    19541952                         return WAIT_ABANDONED;
    19551953                     }
    1956    
     1954
    19571955                     /* otherwise dispatch it */
    19581956                     pfnDispatchMessageA(&msg);
    1959    
     1957
    19601958                  } // end of PeekMessage while loop
    19611959              }
     
    22732271  pHMHandleData->dwShare    = 0;
    22742272  pHMHandleData->dwCreation = 0;
    2275   pHMHandleData->dwFlags    = 0;   
     2273  pHMHandleData->dwFlags    = 0;
    22762274  pHMHandleData->lpHandlerData = NULL;
    22772275
     
    25432541      }
    25442542  }
    2545  
     2543
    25462544  pDeviceHandler = HMGlobals.pHMSemaphore;               /* device is predefined */
    25472545
     
    30263024 *****************************************************************************/
    30273025
    3028 DWORD  HMMsgWaitForMultipleObjects  (DWORD      cObjects, 
     3026DWORD  HMMsgWaitForMultipleObjects  (DWORD      cObjects,
    30293027                                     LPHANDLE   lphObjects,
    30303028                                     BOOL       fWaitAll,
     
    46874685 * Result    :
    46884686 * Remark    :
    4689  * Status    : 
     4687 * Status    :
    46904688 *
    46914689 * Author    : SvL
     
    47484746 * Result    :
    47494747 * Remark    :
    4750  * Status    : 
     4748 * Status    :
    47514749 *
    47524750 * Author    : SvL
     
    47864784 * Result    :
    47874785 * Remark    :
    4788  * Status    : 
     4786 * Status    :
    47894787 *
    47904788 * Author    : SvL
Note: See TracChangeset for help on using the changeset viewer.