Date: Wed, 10 Dec 1997 03:16:04 +1100 (EST) From: Andrew Kenneth Milton <akm@mother.sneaker.net.au> To: jdp@polstra.com (John Polstra) Cc: shigio@wafu.netgate.net, hackers@FreeBSD.ORG Subject: Re: [RFC] path converting functions. Message-ID: <199712091616.DAA20863@mother.sneaker.net.au> In-Reply-To: <199712091541.HAA00577@austin.polstra.com> from "John Polstra" at Dec 9, 97 07:41:18 am
next in thread | previous in thread | raw e-mail | index | archive | help
+-----[ John Polstra ]------------------------------
|
| In article <199712032230.WAA28837@wafu.netgate.net>,
| Shigio Yamaguchi <shigio@wafu.netgate.net> wrote:
|
| >
| > abs2rel - make a relative path name from an absolute path name
| >
| > abs2rel(<original path name>, <base directory>, <result>);
| >
| > <original path name> <base directory> <result>
| > /usr/src /etc ../usr/src
|
| Since your functions write into the user-supplied buffer "result",
| you should add an argument that specifies how big it is.
And always return an error if they haven't allocated MAXPATHLEN :-)
That'll teach 'em.
--
,-_|\ SneakerNet | Andrew Milton | GSM: +61(41)6 022 411
/ \ P.O. Box 154 | akm@sneaker.net.au | Fax: +61(2) 9746 8233
\_,-._/ N Strathfield +--+----------------------+---+ Ph: +61(2) 9746 8233
v NSW 2137 | Low cost Internet Solutions |
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199712091616.DAA20863>
