mirror of
https://github.com/kiwix/kiwix-tools.git
synced 2025-09-22 11:22:38 -04:00
Merge pull request #169 from kiwix/infinit_redirect
Correctly pre-increment the loopCounter.
This commit is contained in:
commit
9997a6ec18
@ -626,7 +626,7 @@ static struct MHD_Response* handle_content(RequestContext* request)
|
||||
if (found) {
|
||||
/* If redirect */
|
||||
unsigned int loopCounter = 0;
|
||||
while (article.isRedirect() && loopCounter++ < 42) {
|
||||
while (article.isRedirect() && ++loopCounter < 42) {
|
||||
article = article.getRedirectArticle();
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user