You "some values" also need to be sane values. You should fill all
size/count related fields of the structure passed to you in statfs.

As for what other file systems do, you can always look at the source
code of an open-source file system yourself. There are *many*. Here's
something you could do:

static int myfs_statfs(const char *path, struct statvfs *buf)
{
...
        buf->f_namemax = 255;
        buf->f_bsize = 4096;
        buf->f_frsize = buf->f_bsize;
        buf->f_blocks = buf->f_bfree =  buf->f_bavail =
                1000ULL * 1024 * 1024 * 1024 / buf->f_frsize;
        buf->f_files = buf->f_ffree = 1000000000;
        return 0;
}

Amit

On May 15, 1:17 am, qabi <[EMAIL PROTECTED]> wrote:
> Hi,
>
> Is the problem with "Zero KB" available space still there? I'm
> implementing a filesystem that returns a statfs with some values for
> blocks, blocksize and free blocks.
>
> But finder shows a correct total size and Zero KB available. Finder
> won't copy files to the volume, probably for the same reason. Copying
> with cp on the commandline just shows "Operation canceled".
>
> Is there any good things that I could do about that? Do anybody know
> what other read/write filesystems do in this regard?
>
> Thanks,
>
> -dennis
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"macfuse-devel" group.
To post to this group, send email to macfuse-devel@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/macfuse-devel?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to