fix linenoiseEdit buflen decreasing.

Hi.

I think there is a bug when you keep room for trailing zero. Can you confirm this please ?

Regards.