Minor refactorings, reduced MG_HTTP_MAX_HEADERS 40 -> 30 to reduce stack usage

This commit is contained in:
cpq committed 2022-08-27 12:31:43 +01:00
1 parent 2d45ba1981
commit 229b492ccc
5 files changed
+46 -42

No files matched your search

+1 -1
View File
@@ -42,7 +42,7 @@ static int packed_stat(const char *path, size_t *size, time_t *mtime) {
static void packed_list(const char *dir, void (*fn)(const char *, void *),
void *userdata) {
char buf[256], tmp[sizeof(buf)];
char buf[MG_PATH_MAX], tmp[sizeof(buf)];
const char *path, *begin, *end;
size_t i, n = strlen(dir);
tmp[0] = '\0'; // Previously listed entry