diff options
author | Nicolas Williams <nico@cryptonector.com> | 2014-12-24 16:48:39 -0600 |
---|---|---|
committer | Nicolas Williams <nico@cryptonector.com> | 2014-12-24 16:49:55 -0600 |
commit | 9e1fd8cf4da04faf1170739923a099e74da61231 (patch) | |
tree | b3c09c270bc23f4e37f9af645de2962f592e6143 /main.c | |
parent | a55085b6620eaadd4c25681c3b744137ba8d30c2 (diff) |
Fix infinite loop in read_more() (fix #656)
Diffstat (limited to 'main.c')
-rw-r--r-- | main.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -154,7 +154,7 @@ const char** input_filenames = NULL; int ninput_files; int next_input_idx; static int read_more(char* buf, size_t size) { - while (!current_input || feof(current_input)) { + if (!current_input || feof(current_input)) { if (current_input) { if (current_input == stdin) { clearerr(stdin); // perhaps we can read again; anyways, we don't fclose(stdin) |