Article View: comp.os.msdos.programmer
Article #5649Re: using "system" in C
From: Tom Reingold
Date: Sat, 06 Apr 1991 03:40
Date: Sat, 06 Apr 1991 03:40
15 lines
1193 bytes
1193 bytes
To my thinking, the solution offered by John Temples is the most
reliable and straightforward. I would add that since you may want to
preserve the timestamp on the file, that you should look into the
stat() and utime() functions. I hope they are provided by your
library. They are in my Microsoft library. Used properly, you can set
the timestamp on the destination file to be the same as that on the
source file.
If you don't have them, use DOS calls. I recommend the former because
they are clones of UNIX calls, thus your program is more portable.
--
Tom Reingold
tr@samadams.princeton.edu OR ...!princeton!samadams!tr
"Warning: Do not drive with Auto-Shade in place. Remove
from windshield before starting ignition."
Technical Details
Message-ID:
<9104060340.AA10600@samadams.Princeton.EDU>Path:
arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!rpi!usc!apple!agate!ucbvax!SAMADAMS.PRINCETON.EDU!trReferences:
<jono.670739550@dec06>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!rpi!usc!apple!agate!ucbvax!SAMADAMS.PRINCETON.EDU!tr From: tr@SAMADAMS.PRINCETON.EDU (Tom Reingold) Newsgroups: comp.os.msdos.programmer Subject: Re: using "system" in C Message-ID: <9104060340.AA10600@samadams.Princeton.EDU> Date: 6 Apr 91 03:40:25 GMT References: <jono.670739550@dec06> Sender: daemon@ucbvax.BERKELEY.EDU Organization: deferred Lines: 15