- Timestamp:
- Nov 25, 2009 10:50:21 AM (15 years ago)
- Location:
- trunk/src/VBox/Main
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Main/Global.cpp
r24626 r24933 213 213 return s_szMsg; 214 214 } 215 216 215 } 217 216 } … … 234 233 return s_szMsg; 235 234 } 236 235 } 236 } 237 238 /*static*/ const char * 239 Global::stringifyDeviceType(DeviceType_T aType) 240 { 241 switch (aType) 242 { 243 case DeviceType_Null: return "Null"; 244 case DeviceType_Floppy: return "Floppy"; 245 case DeviceType_DVD: return "DVD"; 246 case DeviceType_HardDisk: return "HardDisk"; 247 case DeviceType_Network: return "Network"; 248 case DeviceType_USB: return "USB"; 249 case DeviceType_SharedFolder: return "ShardFolder"; 250 default: 251 { 252 AssertMsgFailed(("%d (%#x)\n", aType, aType)); 253 static char s_szMsg[48]; 254 RTStrPrintf(s_szMsg, sizeof(s_szMsg), "InvalidType-0x%08x\n", aType); 255 return s_szMsg; 256 } 237 257 } 238 258 } -
trunk/src/VBox/Main/MediumImpl.cpp
r24905 r24933 338 338 HRESULT Medium::Task::runNow() 339 339 { 340 /* NIL_RTTHREAD indicates synchronous call. */ 340 341 Medium::taskThread(NIL_RTTHREAD, this); 341 342 … … 1933 1934 m->preLockState = m->state; 1934 1935 1935 LogFlowThisFunc(("Okay - prev state=%d \n", m->state));1936 LogFlowThisFunc(("Okay - prev state=%d locationFull=%s\n", m->state, locationFull().c_str())); 1936 1937 m->state = MediumState_LockedWrite; 1937 1938 break; … … 1939 1940 default: 1940 1941 { 1941 LogFlowThisFunc(("Failing - state=%d \n", m->state));1942 LogFlowThisFunc(("Failing - state=%d locationFull=%s\n", m->state, locationFull().c_str())); 1942 1943 rc = setStateError(); 1943 1944 break; … … 1966 1967 { 1967 1968 m->state = m->preLockState; 1968 LogFlowThisFunc(("new state=%d \n", m->state));1969 LogFlowThisFunc(("new state=%d locationFull=%s\n", m->state, locationFull().c_str())); 1969 1970 break; 1970 1971 } 1971 1972 default: 1972 1973 { 1973 LogFlowThisFunc(("Failing - state=%d \n", m->state));1974 LogFlowThisFunc(("Failing - state=%d locationFull=%s\n", m->state, locationFull().c_str())); 1974 1975 rc = setError(VBOX_E_INVALID_OBJECT_STATE, 1975 1976 tr ("Medium '%s' is not locked for writing"), … … 4024 4025 4025 4026 AutoMultiWriteLock2 alock(mVirtualBox->lockHandle(), this->lockHandle()); 4027 LogFlowThisFunc(("aWait=%RTbool locationFull=%s\n", aWait, locationFull().c_str() )); 4026 4028 4027 4029 if ( !(m->formatObj->capabilities() & ( MediumFormatCapabilities_CreateDynamic -
trunk/src/VBox/Main/include/Global.h
r24618 r24933 163 163 164 164 /** 165 * Stringify a device type. 166 * 167 * @returns Pointer to a read only string. 168 * @param aType The device type. 169 */ 170 static const char *stringifyDeviceType(DeviceType_T aType); 171 172 /** 165 173 * Try convert a COM status code to a VirtualBox status code (VBox/err.h). 166 174 *
Note:
See TracChangeset
for help on using the changeset viewer.