Re: directory entry

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




thanks rajat  but i need it in kernel space.
On Tue, Feb 15, 2011 at 5:00 PM, Rajat Sharma <fs.rajat@xxxxxxxxx> wrote:
well just do a readdir and count yourself where you find a match!!

-Rajat

On Tue, Feb 15, 2011 at 4:44 PM, mohit verma <mohit89mlnc@xxxxxxxxx> wrote:
> hi all,
> is there any way to find out the offset or the directory entry number of a
> file in the directory ?
>
> let me explain a bit more:
>
> when we open a drectory via open(2) and find out the directory entry by
> readdir(2,3) or getdents(2) it automatically increases to the next
> directory entry and fills in the dirent structure.
> but in kernel space , let we have the parent directory name and child of it
> . so is there any way to figure out at what  offset or what number (exactly)
> that perticular child will occur in the directory contains?
>
> --
> ........................
> MOHIT VERMA
>
> _______________________________________________
> Kernelnewbies mailing list
> Kernelnewbies@xxxxxxxxxxxxxxxxx
> http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
>
>



--
........................
MOHIT VERMA

_______________________________________________
Kernelnewbies mailing list
Kernelnewbies@xxxxxxxxxxxxxxxxx
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies

[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux