Conversation
Shells like mksh run an external printf, which cannot take a 250KiB page as a single argument. A here-document has no such limit.
Same explanation in three plain lines.
Collaborator
|
Closing this because it is caused by user error in my opinion as laid out in the linked issue. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Type of change
Description
Fixes #1906.
The reporter's shell is mksh, the
/bin/shof Android. It has no builtinprintf, soprintf "%s" "$_response"runs an external printf with the whole page as one argument. Linux allows 128KiB per argument, the search page is 250KiB, so it fails withArgument list too long.Fix: a small
print_pagehelper prints through a here-document. The shell writes that itself, so there is no limit. It is used only where whole pages are printed.Why Termux users end up in mksh:
ani-cli -Urewrites the package's shebang to#!/bin/sh, which is mksh on Android. That is a separate issue and not touched here.Tested with mksh on Android (Termux) and in docker with mksh, dash, bash and busybox: master fails, this branch works.
Checklist
-chistory and continue work-ddownloads work-e(select episode) aka-r(range selection) works-Sselect index works-qquality works-ssyncplay works (not installed)-vvlc works (not installed)--duband regular (sub) mode both work--nextep-countdowncountdown to next ep works-hhelp info is up to date