diff options
author | des <des@FreeBSD.org> | 2000-05-15 08:34:42 +0000 |
---|---|---|
committer | des <des@FreeBSD.org> | 2000-05-15 08:34:42 +0000 |
commit | e10535fbc8ffd8e6c06caa019e617213acf0af7d (patch) | |
tree | 5d84e9a0300860dc9873683a0ba105a87af61955 /lib/libfetch | |
parent | 5d01e7fd741b47ba2507150b88db9f5e11e9a97a (diff) | |
download | FreeBSD-src-e10535fbc8ffd8e6c06caa019e617213acf0af7d.zip FreeBSD-src-e10535fbc8ffd8e6c06caa019e617213acf0af7d.tar.gz |
Document struct url.
Document the default values for fetchStat*().
Diffstat (limited to 'lib/libfetch')
-rw-r--r-- | lib/libfetch/fetch.3 | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/lib/libfetch/fetch.3 b/lib/libfetch/fetch.3 index 0aa75e3..f63089c 100644 --- a/lib/libfetch/fetch.3 +++ b/lib/libfetch/fetch.3 @@ -120,6 +120,28 @@ all URL schemes. For instance, the file scheme only needs the <scheme> and <document> components. .Pp +.Fn fetchParseURL +returns a pointer to a +.Fa url +structure, which is defined as follows in +.Aq Pa fetch.h : +.Bd -literal +#define URL_SCHEMELEN 16 +#define URL_USERLEN 256 +#define URL_PWDLEN 256 + +struct url { + char scheme[URL_SCHEMELEN+1]; + char user[URL_USERLEN+1]; + char pwd[URL_PWDLEN+1]; + char host[MAXHOSTNAMELEN+1]; + int port; + char *doc; + off_t offset; + size_t length; +}; +.Ed +.Pp The pointer returned by .Fn fetchParseURL should be freed using @@ -156,6 +178,16 @@ struct url_stat { }; .Ed .Pp +If the size could not be obtained from the server, the +.Fa size +field is set to -1. +If the modification time could not be obtained from the server, the +.Fa mtime +field is set to the epoch. +If the access time could not be obtained from the server, the +.Fa atime +field is set to the modification time. +.Pp .Fn fetchListURL attempts to list the contents of the directory pointed to by the URL provided. |