check return value of fgets and exit main loop if EOF is received
styling change: remove uneeded parentheses around dereferenced pointer
Merge pull request #35 from freestyl3r/master

Silence the warning about not checking fgets return value