lkml.org 
[lkml]   [2008]   [Apr]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [patch] F_GETPATH for linux
On Mon, 14 Apr 2008, Christoph Hellwig wrote:

> On Sun, Apr 13, 2008 at 03:00:53PM -0700, Davide Libenzi wrote:
> > I was working on some bsd/linux compatibility code, and I noticed that we
> > do not have F_GETPATH. I know we can readlink /proc/PID/fd/FD (that is
> > what I'm doing now, under #ifdef), but I gave a patch a shot anyway.
> > Here it is, building but untested ...
>
> Adding a duplicated API like this is rather pointless. Especially as
> the readlink is easier and makes more sense.

As I said, we can do it in the other way. I struck this one when trying to
work out (read port) some BSD code to Linux. IMO, given that the patch
does virtually only add an F_GETPATH define in fcntl.h, and a case in the
fcntl switch, it may be worth considering.



- Davide




\
 
 \ /
  Last update: 2008-04-14 19:37    [W:0.109 / U:0.620 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site