Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 21 Aug 2006 16:05:33 +0100
From:      "mal content" <artifact.one@googlemail.com>
To:        freebsd-hackers@freebsd.org
Subject:   Relative paths [was: Path transformation]
Message-ID:  <8e96a0b90608210805m561e29e5g41bdd25ff9dfa94c@mail.gmail.com>

next in thread | raw e-mail | index | archive | help
Thanks to all who helped point me towards realpath().

I have another favour to ask: Is there a function that can
take two absolute paths and generate a relative path, from
source to destination?

/usr/bin/false  /bin

Becomes:

../../bin

/bin /usr/bin/false

Becomes:

../usr/bin/false

thanks,
MC



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?8e96a0b90608210805m561e29e5g41bdd25ff9dfa94c>