What do you mean by subdir? Does it require a full directory listing? At least
it would "prime the pump" for the subsequent directory traversal by filling the
cache.

The current directory cache scheme has us add each entry, and then a null entry
to flag the end of the directory. If we need to keep more aggregate data (number
of entries, existence of simultaneous or alarm-capable devices,...) we could
just make a new cache entry to hold all the "aggregate" data. This would also
help eliminate a subtle potential race condition when the directory times out
while being listed.

Paul

-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] Behalf Of
Christian Magnusson
Sent: Friday, April 15, 2005 11:21 AM
To: owfs-developers
Subject: RE: [Owfs-developers] OWFS and FUSE Debugging with UML
(UserMode Linux)



I was trying to fix it this afternoon...

in FS_fstat.c:
        stbuf->st_nlink = 2 ;   // plus number of sub-directories
        stbuf->st_nlink += FS_nr_subdirs(&pn) ;

Tried to read from cache how many subdirs was returned by FS_dir()
but I stumbled into some other problem when I tried to do it.
It seems like I forgot to cache devices returned from ServerDir().

Is it worth the effort of setting st_nlink to the correct value
or should we keep it the way it is?

/Christian



On Fri, 2005-04-15 at 09:49 -0400, Alfille, Paul H.,M.D. wrote: 
> I've asked this question of fuse. This is the response I got:
> 
> From: <[EMAIL PROTECTED]>
>  Re: "find" command   
> 2004-05-11 12:14  
>  use the -noleaf option to find
>  (find uses the following parameters to determine whether it should recurse
>  into a subdirectory)
>  
>  nr_links must be >= 3
>  size must be > 0
>  and must be a driectory
>  
>  so just return those in the getattr for your directories and you wont have
>  to use -noleaf.
>  
>  ---
>  Cody Pisto <[EMAIL PROTECTED]>
>  
>  > I"m having trouble getting the find command to search through fuse
>  > directories. What settings do I need in "getattr"?
>  > 
>  > Paul Alfille
>  > 
>  
> 
> 
> 
> 
> -------------------------------------------------------
> SF email is sponsored by - The IT Product Guide
> Read honest & candid reviews on hundreds of IT Products from real users.
> Discover which products truly live up to the hype. Start reading now.
> http://ads.osdn.com/?ad_ide95&alloc_id396&opÃk
> _______________________________________________
> Owfs-developers mailing list
> Owfs-developers@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/owfs-developers
-- 
Christian Magnusson <[EMAIL PROTECTED]>



-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_ide95&alloc_id396&op=ick
_______________________________________________
Owfs-developers mailing list
Owfs-developers@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/owfs-developers

Reply via email to