Threadpool grows by negative amount when max_threads = 0
|||Rocket Web Server||
While playing around with Rocket, I noticed my threadpool wasn't growing
when I had max_threads set to 0, which should indicate there's no upper
boundary on the maximum number of threads it may create.
I tracked this down to a piece of code in grow() which ensures it never
grows beyond it's max_threads, but didn't take into consideration what
would happen with max_threads set to 0.
(I added a line of comment as well because the first time I saw that line
of code, it wasn't clear to me what it's purpose was.)
I did look at the unit tests, but couldn't see a quick way to test for this
use case, so I'll leave that up to another taker. :)
Setting max_threads to 0 there without this commit causes 3 test failures
though, after my commit, only 1 test failure remains.