Do not memcpy the destination itself
This commit is contained in:
parent
99ccf835b8
commit
8db331c5ff
|
@ -823,7 +823,9 @@ int NDS_CreateDummyFirmware( struct NDS_fw_config_data *user_settings)
|
|||
//Wifi settings CRC16
|
||||
(*(u16*)(MMU.fw.data + 0x2A)) = calc_CRC16(0, (MMU.fw.data + 0x2C), 0x138);
|
||||
|
||||
memcpy(&CommonSettings.InternalFirmConf, user_settings, sizeof(struct NDS_fw_config_data));
|
||||
if (&CommonSettings.InternalFirmConf != user_settings)
|
||||
memcpy(&CommonSettings.InternalFirmConf, user_settings, sizeof(struct NDS_fw_config_data));
|
||||
|
||||
return TRUE ;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue