use of uninitialised value in input_file_open

Triggered by a file containing just "#N" or "#A".  fgets when hitting
EOF before reading anything returns NULL and does not write to buf.
strchr (buf, '\n') then is reading from uninitialised memory.

	* input-file.c (input_file_open): Don't assume buf contains
	zero string terminator when fgets returns NULL.
1 file changed