Changeset 54006 in vbox for trunk/src/VBox/Additions/common/VBoxGuest
- Timestamp:
- Jan 28, 2015 7:39:54 AM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Additions/common/VBoxGuest/VBoxGuest-win.cpp
r53008 r54006 108 108 ULONG ulBuildNo; 109 109 BOOLEAN fCheckedBuild = PsGetVersion(&ulMajorVer, &ulMinorVer, &ulBuildNo, NULL); 110 LogRelFunc(("Running on Windows NT version %u.%u, build %u\n", ulMajorVer, ulMinorVer, ulBuildNo)); 110 111 /* Use RTLogBackdoorPrintf to make sure that this goes to VBox.log */ 112 RTLogBackdoorPrintf("VBoxGuest: Windows version %u.%u, build %u\n", ulMajorVer, ulMinorVer, ulBuildNo); 111 113 if (fCheckedBuild) 112 LogRelFunc(("Running on a Windows checked build (debug)!\n")); 114 RTLogBackdoorPrintf("VBoxGuest: Windows checked build\n"); 115 113 116 #ifdef DEBUG 114 117 vbgdNtDoTests(); … … 116 119 switch (ulMajorVer) 117 120 { 121 case 10: 122 switch (ulMinorVer) 123 { 124 case 0: 125 /* Windows 10 Preview builds starting with 9926. */ 126 default: 127 /* Also everything newer. */ 128 g_enmVbgdNtVer = VBGDNTVER_WIN10; 129 break; 130 } 131 break; 118 132 case 6: /* Windows Vista or Windows 7 (based on minor ver) */ 119 133 switch (ulMinorVer) … … 132 146 break; 133 147 case 4: 148 /* Windows 10 Preview builds. */ 149 default: 150 /* Also everything newer. */ 134 151 g_enmVbgdNtVer = VBGDNTVER_WIN10; 135 break;136 default:137 LogRelFunc(("Unknown version of Windows (%u.%u), refusing!\n", ulMajorVer, ulMinorVer));138 rc = STATUS_DRIVER_UNABLE_TO_LOAD;139 152 break; 140 153 } … … 143 156 switch (ulMinorVer) 144 157 { 158 default: 145 159 case 2: 146 160 g_enmVbgdNtVer = VBGDNTVER_WIN2K3; … … 152 166 g_enmVbgdNtVer = VBGDNTVER_WIN2K; 153 167 break; 154 default:155 LogRelFunc(("Unknown version of Windows (%u.%u), refusing!\n", ulMajorVer, ulMinorVer));156 rc = STATUS_DRIVER_UNABLE_TO_LOAD;157 168 } 158 169 break; … … 161 172 break; 162 173 default: 163 if (ulMajorVer < 4) 164 LogRelFunc(("At least Windows NT4 required! (%u.%u)\n", ulMajorVer, ulMinorVer)); 174 if (ulMajorVer > 6) 175 { 176 /* "Windows 10 mode" for Windows 8.1+. */ 177 g_enmVbgdNtVer = VBGDNTVER_WIN10; 178 } 165 179 else 166 LogRelFunc(("Too new version %u.%u!\n", ulMajorVer, ulMinorVer)); 167 rc = STATUS_DRIVER_UNABLE_TO_LOAD; 180 { 181 if (ulMajorVer < 4) 182 LogRelFunc(("At least Windows NT4 required! (%u.%u)\n", ulMajorVer, ulMinorVer)); 183 else 184 LogRelFunc(("Unknown version %u.%u!\n", ulMajorVer, ulMinorVer)); 185 rc = STATUS_DRIVER_UNABLE_TO_LOAD; 186 } 168 187 break; 169 188 }
Note:
See TracChangeset
for help on using the changeset viewer.