mirror of
https://github.com/RIOT-OS/RIOT.git
synced 2025-01-18 12:52:44 +01:00
Merge pull request #15823 from maribu/fmt-table-bugfix
sys/fmt_table: fix infinite loop
This commit is contained in:
commit
90700f1cec
@ -25,6 +25,7 @@
|
||||
#include <string.h>
|
||||
|
||||
#include "fmt.h"
|
||||
#include "fmt_table.h"
|
||||
|
||||
static const char fmt_table_spaces[16] = " ";
|
||||
|
||||
@ -43,6 +44,7 @@ static void print_pattern(const char *pat, size_t pat_size, size_t fill_size)
|
||||
{
|
||||
while (fill_size > pat_size) {
|
||||
print(pat, pat_size);
|
||||
fill_size -= pat_size;
|
||||
}
|
||||
|
||||
print(pat, fill_size);
|
||||
|
Loading…
Reference in New Issue
Block a user