0
mirror of https://github.com/OneOfEleven/uv-k5-firmware-custom.git synced 2025-06-20 23:18:39 +03:00

Use memcpy() instead of memmove() when it's possible (two memmove call were kept).

Rename some variable named 'String' (to 'str') which is quite confusing.
This commit is contained in:
Daniel Caujolle-Bert
2023-10-24 11:40:35 +02:00
parent 024c4bb79d
commit 64f19b2d78
12 changed files with 317 additions and 317 deletions

View File

@ -122,7 +122,7 @@ bool DTMF_FindContact(const char *pContact, char *pResult)
if (j == 3)
{
memmove(pResult, Contact, 8);
memcpy(pResult, Contact, 8);
pResult[8] = 0;
return true;
}
@ -354,8 +354,8 @@ void DTMF_HandleRequest(void)
memset(g_dtmf_callee, 0, sizeof(g_dtmf_callee));
memset(g_dtmf_caller, 0, sizeof(g_dtmf_caller));
memmove(g_dtmf_callee, g_dtmf_rx + Offset + 0, 3);
memmove(g_dtmf_caller, g_dtmf_rx + Offset + 4, 3);
memcpy(g_dtmf_callee, g_dtmf_rx + Offset + 0, 3);
memcpy(g_dtmf_caller, g_dtmf_rx + Offset + 4, 3);
DTMF_clear_RX();