Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 25 Jan 2012 14:51:51 -0800
From:      Julian Elischer <julian@freebsd.org>
To:        Matthias Zitzen <info@o-notation.org>
Cc:        freebsd-hackers@freebsd.org
Subject:   Re: kqueue and note_rename
Message-ID:  <4F208787.7050605@freebsd.org>
In-Reply-To: <FB8CEF4D-DF60-4E37-930A-4F35E8F33D4F@o-notation.org>
References:  <FB8CEF4D-DF60-4E37-930A-4F35E8F33D4F@o-notation.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On 1/25/12 10:44 AM, Matthias Zitzen wrote:
> Hello list,
> does anybody have an idea, how to obtain the new name of a renamed file after the note_rename event is fired.  I'm not very familiar with filesystem-operations. I checked the typical functions like stat or lstat, but these functions are working only with filenames.

there is no real way.
the new link to the inode could come from any point in the filesystem 
so the
only way to find it would be an exhaustive search.
the only information  that you could return that might make any sense 
would be the inode number of the new parent.
That would allow you to follow the '..' links and do 'pwd' in effect.
I have not checked to see if that information is returned. If it isn't 
it might be a really nice enhancement to see if it could be added.
>
> Matthias
>
> _______________________________________________
> freebsd-hackers@freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
> To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org"
>
>




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