minor clean up

This commit is contained in:
hathach
2023-02-27 09:11:35 +07:00
parent 2e47210c1a
commit e34aeb5cf6
7 changed files with 29 additions and 35 deletions

View File

@@ -24,7 +24,6 @@
* This file is part of the TinyUSB stack.
*/
#include "common/tusb_common.h"
#include "tusb_option.h"
#if CFG_TUH_ENABLED || CFG_TUD_ENABLED
@@ -487,23 +486,3 @@ void tu_print_mem(void const *buf, uint32_t count, uint8_t indent)
#endif
#endif // host or device enabled
//--------------------------------------------------------------------+
// Common
//--------------------------------------------------------------------+
int32_t tu_memset_s(void *dest, size_t destsz, int ch, size_t count) {
if (count > destsz) {
return -1;
}
memset(dest, ch, count);
return 0;
}
int32_t tu_memcpy_s(void *dest, size_t destsz, const void *src, size_t count) {
if (count > destsz) {
return -1;
}
memcpy(dest, src, count);
return 0;
}