Get rid of MG_ENABLE_LOG, change mg_hexdump()

This commit is contained in:
Sergey Lyubka committed 2022-05-06 21:09:13 +01:00
1 parent 6db0485c7b
commit bc16854ccb
13 files changed
+117 -167

No files matched your search

+2 -4
View File
@@ -1426,13 +1426,11 @@ static void test_dns(void) {
}
static void test_util(void) {
char buf[100], *s = mg_hexdump("abc", 3), *p;
char buf[100], *p, *s;
struct mg_addr a;
ASSERT(s != NULL);
free(s);
memset(&a, 0, sizeof(a));
ASSERT(mg_file_printf(&mg_fs_posix, "data.txt", "%s", "hi") == true);
if (system("ls -l") != 0) (void) 0;
// if (system("ls -l") != 0) (void) 0;
ASSERT((p = mg_file_read(&mg_fs_posix, "data.txt", NULL)) != NULL);
ASSERT(strcmp(p, "hi") == 0);
free(p);