[SA-exim] Re: SA-Exim timeout -> use SA 2.1 cvs, not 2.1
Derrick 'dman' Hudson
dman at dman.ddts.net
Tue, 22 Oct 2002 12:35:44 -0400
---------------------- multipart/signed attachment
On Tue, Oct 22, 2002 at 02:23:10AM -0700, Marc MERLIN wrote:
| BTW, if a real C programmer can answer this for me:
| /* Ok, tell me what's the better way of getting the size of the file =
an fd
| * points to */
You should stat it.
Excerpts from stat(2) :
int fstat(int filedes, struct stat *buf);
These functions return information about the specified file. You=
do
not need any access rights to the file to get this information but =
you
need search rights to all directories named in the path leading to =
the
file.
They all return a stat structure, which contains the following field=
s:
struct stat {
dev_t st_dev; /* device */
ino_t st_ino; /* inode */
mode_t st_mode; /* protection */
nlink_t st_nlink; /* number of hard links */
uid_t st_uid; /* user ID of owner */
gid_t st_gid; /* group ID of owner */
dev_t st_rdev; /* device type (if inode devic=
e) */
off_t st_size; /* total size, in bytes */
blksize_t st_blksize; /* blocksize for filesystem I/=
O */
blkcnt_t st_blocks; /* number of blocks allocated =
*/
time_t st_atime; /* time of last access */
time_t st_mtime; /* time of last modification */
time_t st_ctime; /* time of last change */
};
-D
--=20
If anyone would come after me, he must deny himself and take up his
cross and follow me. For whoever wants to save his life will lose it,
but whoever loses his life for me and for the gospel will save it. What
good is it for a man to gain the whole world, yet forfeit his soul? Or
what can a man give in exchange for his soul?
Mark 8:34-37
=20
http://dman.ddts.net/~dman/
---------------------- multipart/signed attachment
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 240 bytes
Desc: not available
Url : http://lists.merlins.org/archives/sa-exim/attachments/20021022/2d6bb54a/attachment.bin
---------------------- multipart/signed attachment--