mirror of
				https://git.proxmox.com/git/fwupd
				synced 2025-11-04 03:33:24 +00:00 
			
		
		
		
	Correctly mark updates as successful even if the device version number is wrong
If the device firmware was set incorrectly make then set it to the release version so the database update works correctly. We can't do any kind of vercmp in the database, so use a daemon warning so we can either fix the plugin or the XML. This fixes up the issue that the hardware reports '28.00' and the AppStream release specifies '28.0'. Fixes: https://github.com/hughsie/fwupd/issues/387
This commit is contained in:
		
							parent
							
								
									a31895b316
								
							
						
					
					
						commit
						4082d3367b
					
				@ -1649,6 +1649,13 @@ fu_engine_install (FuEngine *self,
 | 
			
		||||
						 error);
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	/* ensure the new version matched what we expected */
 | 
			
		||||
	if (g_strcmp0 (fu_device_get_version (device), version) != 0) {
 | 
			
		||||
		g_warning ("new device version '%s' was is not '%s', fixing up",
 | 
			
		||||
			   fu_device_get_version (device), version);
 | 
			
		||||
		fu_device_set_version (device, version);
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	/* success */
 | 
			
		||||
	fu_device_set_update_state (device, FWUPD_UPDATE_STATE_SUCCESS);
 | 
			
		||||
	return fu_history_modify_device (self->history, device,
 | 
			
		||||
 | 
			
		||||
		Loading…
	
		Reference in New Issue
	
	Block a user