Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

str2str readcmd: avoid constant sizes #560

Open
wants to merge 1 commit into
base: demo5
Choose a base branch
from

Conversation

ourairquality
Copy link

MAXSTR was not the appropriate definition of the buffer size here as it is the number of streams which is distinct from the command line read chunk size. Use a read chuck size of 81 characters.

Pass in the target cmd size, rather than depending on MAXRCVCMD.

Exit as soon as the target is full, rather than filling with smaller later chucks, and emit a warning on overflow.

MAXSTR was not the appropriate definition of the buffer size here as
it is the number of streams which is distinct from the command line
read chunk size. Use a read chuck size of 81 characters.

Pass in the target cmd size, rather than depending on MAXRCVCMD.

Exit as soon as the target is full, rather than filling with smaller
later chucks, and emit a warning on overflow.

Only accept the separator character @ at the start of a line and
flush to the end of this line.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant