It is possible that `make_error_msg` gets called multiple times (when a file is not found), that looks like a valid memleak to me? (See the `while(1)` below.)