mirror of
				https://github.com/pbatard/rufus.git
				synced 2024-08-14 23:57:05 +00:00 
			
		
		
		
	[core] fix wrong detection of Buffalo, Lacie, Samsung, Toshiba and Verbatim drives as HDDs
* Remove the ill-advised (and problematic) table lookup microoptimization * Also display score when running in debug mode
This commit is contained in:
		
							parent
							
								
									c3eaaf86a3
								
							
						
					
					
						commit
						d5bb6bfe6f
					
				
					 3 changed files with 11 additions and 11 deletions
				
			
		|  | @ -6,8 +6,9 @@ o Version 1.4.8 (2014.06.??) | |||
|     Add Latvian translation, courtesy of Aldis Tutins | ||||
|     Allow the use of VHDs as DD image source (fixed disk/uncompressed only) | ||||
|     Report the detected USB speed in the log | ||||
|     Fix a long standing issue when launching Rufus from Far Manager | ||||
|     Fix a long standing issue when launching Rufus using Far Manager | ||||
|     Fix support for pure UEFI bootable disk images | ||||
|     Fix detection for some Buffalo, Lacie, Samsung, Toshiba and Verbatim drives | ||||
|     Various other fixes and improvements | ||||
| 
 | ||||
| o Version 1.4.7 (2014.04.22) | ||||
|  |  | |||
							
								
								
									
										12
									
								
								src/rufus.rc
									
										
									
									
									
								
							
							
						
						
									
										12
									
								
								src/rufus.rc
									
										
									
									
									
								
							|  | @ -32,7 +32,7 @@ LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL | |||
| 
 | ||||
| IDD_DIALOG DIALOGEX 12, 12, 206, 329 | ||||
| STYLE DS_SETFONT | DS_MODALFRAME | DS_FIXEDSYS | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU | ||||
| CAPTION "Rufus 1.4.8.495" | ||||
| CAPTION "Rufus 1.4.8.496" | ||||
| FONT 8, "MS Shell Dlg", 400, 0, 0x1 | ||||
| BEGIN | ||||
|     DEFPUSHBUTTON   "Start",IDC_START,94,291,50,14 | ||||
|  | @ -165,7 +165,7 @@ END | |||
| RTL_IDD_DIALOG DIALOGEX 12, 12, 206, 329 | ||||
| STYLE DS_SETFONT | DS_MODALFRAME | DS_FIXEDSYS | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU | ||||
| EXSTYLE WS_EX_RTLREADING | WS_EX_APPWINDOW | WS_EX_LAYOUTRTL | ||||
| CAPTION "Rufus 1.4.8.495" | ||||
| CAPTION "Rufus 1.4.8.496" | ||||
| FONT 8, "MS Shell Dlg", 400, 0, 0x1 | ||||
| BEGIN | ||||
|     DEFPUSHBUTTON   "Start",IDC_START,94,291,50,14 | ||||
|  | @ -428,8 +428,8 @@ END | |||
| // | ||||
| 
 | ||||
| VS_VERSION_INFO VERSIONINFO | ||||
|  FILEVERSION 1,4,8,495 | ||||
|  PRODUCTVERSION 1,4,8,495 | ||||
|  FILEVERSION 1,4,8,496 | ||||
|  PRODUCTVERSION 1,4,8,496 | ||||
|  FILEFLAGSMASK 0x3fL | ||||
| #ifdef _DEBUG | ||||
|  FILEFLAGS 0x1L | ||||
|  | @ -446,13 +446,13 @@ BEGIN | |||
|         BEGIN | ||||
|             VALUE "CompanyName", "Akeo Consulting (http://akeo.ie)" | ||||
|             VALUE "FileDescription", "Rufus" | ||||
|             VALUE "FileVersion", "1.4.8.495" | ||||
|             VALUE "FileVersion", "1.4.8.496" | ||||
|             VALUE "InternalName", "Rufus" | ||||
|             VALUE "LegalCopyright", "© 2011-2014 Pete Batard (GPL v3)" | ||||
|             VALUE "LegalTrademarks", "http://www.gnu.org/copyleft/gpl.html" | ||||
|             VALUE "OriginalFilename", "rufus.exe" | ||||
|             VALUE "ProductName", "Rufus" | ||||
|             VALUE "ProductVersion", "1.4.8.495" | ||||
|             VALUE "ProductVersion", "1.4.8.496" | ||||
|         END | ||||
|     END | ||||
|     BLOCK "VarFileInfo" | ||||
|  |  | |||
|  | @ -474,8 +474,6 @@ int IsHDD(DWORD DriveIndex, uint16_t vid, uint16_t pid, const char* strid) | |||
| 
 | ||||
| 	// Check against known VIDs
 | ||||
| 	for (i=0; i<ARRAYSIZE(vid_score); i++) { | ||||
| 		if (vid < vid_score[i].vid) | ||||
| 			break; | ||||
| 		if (vid == vid_score[i].vid) { | ||||
| 			score += vid_score[i].score; | ||||
| 			break; | ||||
|  | @ -484,8 +482,6 @@ int IsHDD(DWORD DriveIndex, uint16_t vid, uint16_t pid, const char* strid) | |||
| 
 | ||||
| 	// Check against known VID:PIDs
 | ||||
| 	for (i=0; i<ARRAYSIZE(vidpid_score); i++) { | ||||
| 		if (vid < vidpid_score[i].vid) | ||||
| 			break; | ||||
| 		if ((vid == vidpid_score[i].vid) && (pid == vidpid_score[i].pid)) { | ||||
| 			score += vidpid_score[i].score; | ||||
| 			break; | ||||
|  | @ -493,5 +489,8 @@ int IsHDD(DWORD DriveIndex, uint16_t vid, uint16_t pid, const char* strid) | |||
| 	} | ||||
| 
 | ||||
| 	// TODO: try to perform inquiry if below a specific threshold (Verbatim, etc)?
 | ||||
| #if defined(_DEBUG) | ||||
| 	uprintf("  Score: %d\n", score); | ||||
| #endif | ||||
| 	return score; | ||||
| } | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue