Changing Timestamp

Hi, i m working on a project to simulate the behavior of touch command using c programming in linux. I can create the file easily but can't change the time stamp as in touch command.
I m passing the file name on command line.
Plz hlp me.
The thing about open source, is that you can see the source.

This is the source code for touch on FreeBSD 9.1.0
http://svnweb.FreeBSD.org/base/release/9.1.0/usr.bin/touch/touch.c?revision=243808&view=markup

See line 206 for the answer.
thank u
Topic archived. No new replies allowed.