About using ctime

Discussion in 'C Programming' started by parag_paul@hotmail.com, Oct 7, 2008.

  1. Guest

    I am try ing to use ctime with the type time_t ,

    I used
    ....

    time_t t = time(0);
    char* sc = ctime( &t);
    printf ("%s\n", sc);

    ....

    it crashes for 64 bit compilations but does file with gcc -m32,

    Is there a any fix to this problem, I am searching for a 64 bit
    compatible definition for ctime , is it available by default
     
    , Oct 7, 2008
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Ernst Murnleitner

    replacement for <ctime>?

    Ernst Murnleitner, Jul 16, 2003, in forum: C++
    Replies:
    8
    Views:
    545
    Limech
    Jul 20, 2003
  2. Tivo Escobar

    Question about ctime

    Tivo Escobar, Jul 23, 2003, in forum: C++
    Replies:
    1
    Views:
    404
    Victor Bazarov
    Jul 23, 2003
  3. Oplec
    Replies:
    2
    Views:
    530
    Oplec
    Oct 26, 2003
  4. Kevin

    ctime Help

    Kevin, May 16, 2004, in forum: C++
    Replies:
    3
    Views:
    803
    osmium
    May 16, 2004
  5. wukexin
    Replies:
    1
    Views:
    480
    Karl Heinz Buchegger
    May 25, 2005
Loading...

Share This Page