title: C exit from infinite loop on keypress
body: <p>How can I exit from an infinite loop, when a key is pressed?
  Currently I'm using getch, but it will start blocking my loop as soon, as there is no more input to read.</p>