[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [lwip-users] makefs and mem_free errors
From: |
address@hidden |
Subject: |
Re: [lwip-users] makefs and mem_free errors |
Date: |
Tue, 2 Apr 2019 20:45:01 +0200 |
User-agent: |
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:60.0) Gecko/20100101 Thunderbird/60.6.0 |
Am 02.04.2019 um 20:39 schrieb Mike Spenard:
Correct, I misspoke... I simply meant 'generated' fsdata.c rather than
compiled.
I traced the "mem_free: mem->used" bomb out to the 404.html missing from
fsdata.c
The http_get_404_file() function checks for it missing:
if (err != ERR_OK) {
/* 404.htm doesn't exist either. Indicate to the caller that it
should
* send back a default 404 page.
*/
*uri = NULL;
return NULL;
...however, http_find_file() doesn’t have any code to properly handle that
NULL:
Hmm, that might still be missing in HEAD, too. I never checked, I guess.
} else {
file = http_get_404_file(hs, &uri);
}
I assume this is why I end up with a pbuf structure of heap allocated by
never flagged as Used. Which causes free_mem() to bomb out ...?
Might be.
I'm a new player here, so has this been fixed in newer code than NXP
provided me with? Or am I misunderstanding things?
No, seems to be in here still. We had some handling for a compiled-in
default 404 page, don't know what happened to that.
Would you mind filing a bug so that this doesn't get forgotten?
Regards,
Simon