title: fgets() doesn't correctly parse the data as I want
body: <p>I'm currently parsing '.dat' file by using fgets() as below.</p>
  <pre><code>#include &lt;iostream&gt;
  
  int main(int argc, char **argv) 
  {
      FILE *fp = fopen( argv[1], &quot;r+&quot;);   
      unsigned char pu8bufsend[256];
      printf(&quot;%s\n&quot;, argv[1]);    
      fseek(fp, 58, SEEK_SET);
      
      while(fgets((char*)pu8bufsend, 128*2, fp) != NULL)
      {
          for (size_t j = 0; j &lt; 256; j++)
          {        
              printf(&quot;%02x , %d\n&quot;, pu8bufsend[j], j);        
          }
      }    
      
  }
  </code></pre>
  <p>When I parse a certain '.dat' file, the first 20 outputs look as below.</p>
  <pre><code>c0 , 0
  a8 , 1
  0a , 2
  00 , 3
  00 , 4
  00 , 5
  00 , 6
  00 , 7
  86 , 8
  aa , 9
  2b , 10
  1d , 11
  ff , 12
  7f , 13
  00 , 14
  00 , 15
  e8 , 16
  7a , 17
  40 , 18
  00 , 19
  00 , 20
  </code></pre>
  <p>However, I'm supposed to get this highlighted part from the '.dat' file.</p>
  <p><a href="https://i.stack.imgur.com/6coR5.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/6coR5.png" alt="enter image description here" /></a></p>
  <p>It's supposed to be really simple but don't get why I'm struggling so much for this.</p>
  <p>Can anyone figure out my problem?</p>