B#13033: Incorrect node and radio instance in dmmap_mapcontroller

This commit is contained in:
Amin Ben Romdhane 2023-12-22 12:17:16 +01:00
parent 0f5ef9c5f6
commit 351417e079
3 changed files with 323 additions and 1278 deletions

File diff suppressed because it is too large Load diff

View file

@ -1854,6 +1854,22 @@ void string_to_mac(const char *str, size_t str_len, char *out, size_t out_len)
}
}
void remove_char(char *str, const char c)
{
int i = 0, j = 0;
if (DM_STRLEN(str) == 0)
return;
while (str[i]) {
if (str[i] != c)
str[j++] = str[i];
i++;
}
str[j] = 0;
}
char *replace_char(char *str, char find, char replace)
{
char *current_pos = DM_STRCHR(str, find);

View file

@ -280,6 +280,7 @@ bool folder_exists(const char *path);
bool file_exists(const char *path);
bool is_regular_file(const char *path);
unsigned long file_system_size(const char *path, const enum fs_size_type_enum type);
void remove_char(char *str, const char c);
char *replace_char(char *str, char find, char replace);
char *replace_str(const char *str, const char *substr, const char *replacement);
int dm_file_to_buf(const char *filename, void *buf, size_t buf_size);