title: Correctly recording the UNIX time in C (-Wall nightmare)
body: <blockquote>
    <p><strong>Possible Duplicate:</strong><br>
    <a href="https://stackoverflow.com/questions/2792551/what-primitive-data-type-is-time-t">What primitive data type is time_t?</a>  </p>
  </blockquote>
  
  
  
  <p>Basically, all I want to do is produce the current UNIX time (result from time(NULL)) and print it to a file I have open.</p>
  
  <p>I've tried code such as:</p>
  
  <pre><code>fprintf(f, "%i", time(NULL));
  </code></pre>
  
  <p>But I get these annoying compiler warnings:</p>
  
  <pre><code>src/database-createtbl.c:140: warning: int format, time_t arg (arg 3)
  </code></pre>
  
  <p>I'm trying to compile using -Wall - this really shouldn't be an issue but it's driving me nuts.</p>