This was clearly a typo, but it could potentially cause a buffer overflow if PATH_MAX is larger than BUFSIZ.
change line size from PATH_MAX to BUFSIZ
Unfortunately, this is prone to the same bit rot that caused this potential overflow. I pushed b063272 to deal with this using sizeof.
Thanks for the report.