Closed sni closed 1 year ago
that's right, but in my case i had command with very long arguments like example_command!some very long arg!other arg
and it was cut off, if the argument was more than 8k.
You had a single argument that was above 8k bytes!?
right, basically a tarball of a folder as base64 encoded string :-) I know, not the usual usecase, but naemon should either work or throw an error :-)
When I first read the title I figured it would be the total check_command (expanded/non expanded) that we change, so I guess just make sure to note in the changelog that it's the size of the individual command line args that can now be longer.
Honestly, I was also testing the total check command length first^^
sorry for the confusion :-) i will try to make the changelog entry more clear.
thanks for the review.
Previously we used a fixed size 8k buffer when parsing command line arguments. This sounds much, but there are command lines bigger than 8k and they are simply cut off without any warning.
Instead we use a dynamic sized buffer with the size of the raw command now.
(while on it, fixing the crazy indent)