mirror of
https://github.com/kiwix/kiwix-tools.git
synced 2025-09-25 05:10:29 -04:00
* FIXED: kiwix-serve crahs if really long URL (#400)
This commit is contained in:
parent
a861e378af
commit
581362a43a
@ -211,6 +211,7 @@ static int accessHandlerCallback(void *cls,
|
||||
|
||||
/* Display the search restults */
|
||||
else if (!strcmp(url, "/search")) {
|
||||
|
||||
/* Retrieve the pattern to search */
|
||||
const char* pattern = MHD_lookup_connection_value(connection, MHD_GET_ARGUMENT_KIND, "pattern");
|
||||
if (pattern == NULL)
|
||||
@ -264,7 +265,6 @@ static int accessHandlerCallback(void *cls,
|
||||
pthread_mutex_lock(&readerLock);
|
||||
try {
|
||||
found = reader->getContentByUrl(urlStr, content, contentLength, mimeType);
|
||||
|
||||
if (found) {
|
||||
if (isVerbose()) {
|
||||
cout << "Found " << urlStr << endl;
|
||||
|
Loading…
x
Reference in New Issue
Block a user