title: Using fseek to backtrack
body: <p>Is using <code>fseek</code> to backtrack character <code>fscanf</code> operations reliable?</p>
  
  <p>Like for example if I have just <code>fscanf</code>-ed 10 characters but I would like to backtrack the 10 chars can I just <code>fseek(infile, -10, SEEK_CUR)</code> ? </p>
  
  <p>For most situations it works but I seem to have problems with the character <code>^M</code>. Apparently <code>fseek</code> registers it as a char but <code>fscanf</code> doesn't register it, thus in my previous example a 10 char block containing a <code>^M</code> would require <code>fseek(infile, -11, SEEK_CUR)</code> instead. <code>fseek(infile, -10, SEEK_CUR)</code> would make bring it short by 1 character.</p>
  
  <p>Why is this so? </p>
  
  <p>Edit: I was using <code>fopen</code> in text mode</p>