| TIP: Click on subject to list as thread! | ANSI |
| echo: | |
|---|---|
| to: | |
| from: | |
| date: | |
| subject: | posix |
PE> I checked the posix standard, stat() is in there, operates on a
PE> filename, include and to get it. The
PE> dates are all of type time_t, so you can use strftime() on
PE> them.
Borland says the opposite about their stat struct, but strftime()
won't work in Unix anyway. I've had to write my own. What I am trying
to do is write a library of simple file and directory functions that
will work DOS/Windows/UNIX.
If you just call stat() and use the struct as time_t you will get
daylight savings time for New York (that's what *I* got, anyway). To
make stat() work you have to explicity put
timezone = 0;
daylight = 0;
and then ctime() won't work!
I love C. It's such a great language... and so portable, too.
PE> The Posix standard further restricts time_t to be the number of
PE> seconds since 1970, although they don't make that clear
I thought Borland made it pretty clear it wasn't. But I can't use
the time_t variable anyway, in UNIX.
PE> (Posix was created by dickheads - who else would make fork()
PE> part of the standard when hardly anyone can do one of them, and
PE> most people really are just trying to do an spawn() when they
PE> use fork() (because they follow it with an exec())).
You used one too many brackets.
Regards,
Bob
___ Blue Wave/QWK v2.12
@EOT:
---
* Origin: Precision Nonsense, Sydney (3:711/934.12)SEEN-BY: 711/934 712/610 @PATH: 711/934 |
|
| SOURCE: echomail via fidonet.ozzmosis.com | |
Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.