1998-08-25 20:00:16 +04:00
|
|
|
/*
|
|
|
|
* Single File fileSystem
|
|
|
|
*
|
|
|
|
* Copyright 1998 Pavel Machek, distribute under GPL
|
|
|
|
*
|
|
|
|
* This defines whole class of filesystems which contain single file
|
|
|
|
* inside. It is somehow similar to extfs, except that extfs makes
|
1998-09-14 12:14:31 +04:00
|
|
|
* whole virtual trees and we do only single virtual files.
|
1998-10-13 02:07:53 +04:00
|
|
|
*
|
1998-10-23 12:26:25 +04:00
|
|
|
* If you want to gunzip something, you should open it with #ugz
|
|
|
|
* suffix, DON'T try to gunzip it yourself.
|
|
|
|
*
|
|
|
|
* Namespace: exports vfs_sfs_ops, shell (FIXME) */
|
1998-08-25 20:00:16 +04:00
|
|
|
|
|
|
|
#include <config.h>
|
|
|
|
#include <errno.h>
|
|
|
|
#include <sys/types.h>
|
|
|
|
#include <unistd.h>
|
|
|
|
#include <stdio.h>
|
|
|
|
#include <string.h>
|
|
|
|
#include <fcntl.h>
|
1999-01-21 01:01:11 +03:00
|
|
|
|
|
|
|
#include "utilvfs.h"
|
1998-08-25 20:00:16 +04:00
|
|
|
|
|
|
|
#include "vfs.h"
|
1998-12-15 22:53:55 +03:00
|
|
|
#include "local.h"
|
1998-08-25 20:00:16 +04:00
|
|
|
|
1998-10-13 02:07:53 +04:00
|
|
|
/* This is needed, or libvfs.so will lack symbol shell. Should look up who requires it */
|
1998-09-27 23:27:58 +04:00
|
|
|
char *shell = "/bin/sh";
|
1998-08-25 20:00:16 +04:00
|
|
|
|
|
|
|
struct cachedfile {
|
|
|
|
char *name, *cache;
|
|
|
|
uid_t uid;
|
|
|
|
struct cachedfile *next;
|
|
|
|
};
|
|
|
|
|
|
|
|
static struct cachedfile *head;
|
|
|
|
|
|
|
|
#define MAXFS 32
|
|
|
|
static int sfs_no = 0;
|
|
|
|
static char *sfs_prefix[ MAXFS ];
|
|
|
|
static char *sfs_command[ MAXFS ];
|
|
|
|
static int sfs_flags[ MAXFS ];
|
|
|
|
#define F_1 1
|
|
|
|
#define F_2 2
|
|
|
|
#define F_NOLOCALCOPY 4
|
|
|
|
#define F_FULLMATCH 8
|
|
|
|
|
1999-01-11 03:48:23 +03:00
|
|
|
static int uptodate (char *name, char *cache)
|
1998-08-25 20:00:16 +04:00
|
|
|
{
|
|
|
|
return 1;
|
|
|
|
}
|
|
|
|
|
1999-01-11 03:48:23 +03:00
|
|
|
static int vfmake (vfs *me, char *name, char *cache)
|
1998-08-25 20:00:16 +04:00
|
|
|
{
|
|
|
|
char *inpath, *op;
|
|
|
|
int w;
|
|
|
|
char pad [10240];
|
|
|
|
char *s, *t = pad;
|
|
|
|
int was_percent = 0;
|
|
|
|
|
1999-01-11 03:48:23 +03:00
|
|
|
vfs_split (name, &inpath, &op);
|
|
|
|
if ((w = (*me->which) (me, op)) == -1)
|
|
|
|
vfs_die ("This cannot happen... Hopefully.\n");
|
1998-08-25 20:00:16 +04:00
|
|
|
|
1999-01-11 03:48:23 +03:00
|
|
|
if ((sfs_flags[w] & F_1) || (!strcmp (name, "/"))) ; else return -1;
|
1998-08-25 20:00:16 +04:00
|
|
|
/* if ((sfs_flags[w] & F_2) || (!inpath) || (!*inpath)); else return -1; */
|
1999-08-18 23:08:56 +04:00
|
|
|
if (!(sfs_flags[w] & F_NOLOCALCOPY)) {
|
|
|
|
s = mc_getlocalcopy (name);
|
|
|
|
if (!s)
|
|
|
|
return -1;
|
|
|
|
name = name_quote (s, 0);
|
|
|
|
g_free (s);
|
|
|
|
} else
|
|
|
|
name = name_quote (name, 0);
|
2000-05-16 18:59:33 +04:00
|
|
|
#define COPY_CHAR if (t-pad>sizeof(pad)) { g_free (name); return -1; } else *t++ = *s;
|
|
|
|
#define COPY_STRING(a) if ((t-pad)+strlen(a)>sizeof(pad)) { g_free (name); return -1; } else { strcpy (t, a); t+= strlen(a); }
|
|
|
|
for (s = sfs_command[w]; *s; s++) {
|
1998-08-25 20:00:16 +04:00
|
|
|
if (was_percent) {
|
2000-05-16 18:59:33 +04:00
|
|
|
|
|
|
|
char *ptr = NULL;
|
|
|
|
was_percent = 0;
|
|
|
|
|
1998-08-25 20:00:16 +04:00
|
|
|
switch (*s) {
|
2000-05-16 18:59:33 +04:00
|
|
|
case '1': ptr = name; break;
|
|
|
|
case '2': ptr = op + strlen (sfs_prefix[w]); break;
|
|
|
|
case '3': ptr = cache; break;
|
|
|
|
case '%': COPY_CHAR; continue;
|
1998-08-25 20:00:16 +04:00
|
|
|
}
|
2000-05-16 18:59:33 +04:00
|
|
|
COPY_STRING (ptr);
|
1998-08-25 20:00:16 +04:00
|
|
|
} else {
|
1999-01-11 03:48:23 +03:00
|
|
|
if (*s == '%')
|
|
|
|
was_percent = 1;
|
|
|
|
else
|
|
|
|
COPY_CHAR;
|
1998-08-25 20:00:16 +04:00
|
|
|
}
|
|
|
|
}
|
1999-01-21 01:01:11 +03:00
|
|
|
g_free (name);
|
1998-08-25 20:00:16 +04:00
|
|
|
|
1999-01-11 03:48:23 +03:00
|
|
|
if (my_system (EXECUTE_AS_SHELL | EXECUTE_SETUID | EXECUTE_WAIT, "/bin/sh", pad)) {
|
1998-08-25 20:00:16 +04:00
|
|
|
return -1;
|
|
|
|
}
|
|
|
|
|
|
|
|
return 0; /* OK */
|
|
|
|
}
|
|
|
|
|
1999-01-11 03:48:23 +03:00
|
|
|
static char *
|
|
|
|
redirect (vfs *me, char *name)
|
1998-08-25 20:00:16 +04:00
|
|
|
{
|
|
|
|
struct cachedfile *cur = head;
|
|
|
|
uid_t uid = vfs_uid;
|
2000-05-16 18:59:33 +04:00
|
|
|
char *cache;
|
1998-12-15 18:57:39 +03:00
|
|
|
int handle;
|
1998-08-25 20:00:16 +04:00
|
|
|
|
1999-01-11 03:48:23 +03:00
|
|
|
while (cur){
|
|
|
|
if ((!strcmp (name, cur->name)) &&
|
1998-08-25 20:00:16 +04:00
|
|
|
(uid == cur->uid) &&
|
1999-01-11 03:48:23 +03:00
|
|
|
(uptodate (cur->name, cur->cache)))
|
|
|
|
/* FIXME: when not uptodate, we might want to kill cache
|
|
|
|
* file immediately, not to wait until timeout. */ {
|
|
|
|
vfs_stamp (&vfs_sfs_ops, cur);
|
|
|
|
return cur->cache;
|
1998-09-14 12:14:31 +04:00
|
|
|
}
|
1998-08-25 20:00:16 +04:00
|
|
|
cur = cur->next;
|
|
|
|
}
|
1999-01-11 03:48:23 +03:00
|
|
|
|
|
|
|
cache = tempnam (NULL, "sfs");
|
|
|
|
handle = open (cache, O_RDWR | O_CREAT | O_EXCL, 0600);
|
2000-05-16 18:59:33 +04:00
|
|
|
if (handle == -1) {
|
|
|
|
g_free (cache);
|
|
|
|
return "/SOMEONE_PLAYING_DIRTY_TMP_TRICKS_ON_US";
|
|
|
|
}
|
1998-12-15 18:57:39 +03:00
|
|
|
|
1999-01-11 03:48:23 +03:00
|
|
|
close (handle);
|
|
|
|
|
|
|
|
if (!vfmake (me, name, cache)){
|
2000-05-16 18:59:33 +04:00
|
|
|
cur = g_new (struct cachedfile, 1);
|
|
|
|
cur->name = g_strdup (name);
|
1999-01-11 03:48:23 +03:00
|
|
|
cur->cache = cache;
|
1998-08-25 20:00:16 +04:00
|
|
|
cur->uid = uid;
|
|
|
|
cur->next = head;
|
|
|
|
head = cur;
|
1998-09-14 12:14:31 +04:00
|
|
|
|
1998-10-13 02:07:53 +04:00
|
|
|
vfs_add_noncurrent_stamps (&vfs_sfs_ops, (vfsid) head, NULL);
|
1998-09-14 12:14:31 +04:00
|
|
|
vfs_rm_parents (NULL);
|
|
|
|
|
1998-08-25 20:00:16 +04:00
|
|
|
return cache;
|
|
|
|
}
|
2000-05-16 18:59:33 +04:00
|
|
|
g_free (cache);
|
1998-08-25 20:00:16 +04:00
|
|
|
return "/I_MUST_NOT_EXIST";
|
|
|
|
}
|
|
|
|
|
1999-01-11 03:48:23 +03:00
|
|
|
static void *
|
|
|
|
sfs_open (vfs *me, char *path, int flags, int mode)
|
1998-08-25 20:00:16 +04:00
|
|
|
{
|
|
|
|
int *sfs_info;
|
|
|
|
int fd;
|
|
|
|
|
1999-01-11 03:48:23 +03:00
|
|
|
path = redirect (me, path);
|
1998-08-25 20:00:16 +04:00
|
|
|
fd = open (path, flags, mode);
|
|
|
|
if (fd == -1)
|
|
|
|
return 0;
|
|
|
|
|
1999-01-21 01:01:11 +03:00
|
|
|
sfs_info = g_new (int, 1);
|
1998-08-25 20:00:16 +04:00
|
|
|
*sfs_info = fd;
|
|
|
|
|
|
|
|
return sfs_info;
|
|
|
|
}
|
|
|
|
|
1998-09-27 23:27:58 +04:00
|
|
|
static int sfs_stat (vfs *me, char *path, struct stat *buf)
|
1998-08-25 20:00:16 +04:00
|
|
|
{
|
1999-01-11 03:48:23 +03:00
|
|
|
path = redirect (me, path);
|
1998-08-25 20:00:16 +04:00
|
|
|
return stat (path, buf);
|
|
|
|
}
|
|
|
|
|
1998-09-27 23:27:58 +04:00
|
|
|
static int sfs_lstat (vfs *me, char *path, struct stat *buf)
|
1998-08-25 20:00:16 +04:00
|
|
|
{
|
1999-01-11 03:48:23 +03:00
|
|
|
path = redirect (me, path);
|
1998-08-25 20:00:16 +04:00
|
|
|
#ifndef HAVE_STATLSTAT
|
|
|
|
return lstat (path,buf);
|
|
|
|
#else
|
|
|
|
return statlstat (path, buf);
|
|
|
|
#endif
|
|
|
|
}
|
|
|
|
|
1998-09-27 23:27:58 +04:00
|
|
|
static int sfs_chmod (vfs *me, char *path, int mode)
|
1998-08-25 20:00:16 +04:00
|
|
|
{
|
1999-01-11 03:48:23 +03:00
|
|
|
path = redirect (me, path);
|
1998-08-25 20:00:16 +04:00
|
|
|
return chmod (path, mode);
|
|
|
|
}
|
|
|
|
|
1998-09-27 23:27:58 +04:00
|
|
|
static int sfs_chown (vfs *me, char *path, int owner, int group)
|
1998-08-25 20:00:16 +04:00
|
|
|
{
|
1999-01-11 03:48:23 +03:00
|
|
|
path = redirect (me, path);
|
1998-08-25 20:00:16 +04:00
|
|
|
return chown (path, owner, group);
|
|
|
|
}
|
|
|
|
|
1998-09-27 23:27:58 +04:00
|
|
|
static int sfs_utime (vfs *me, char *path, struct utimbuf *times)
|
1998-08-25 20:00:16 +04:00
|
|
|
{
|
1999-01-11 03:48:23 +03:00
|
|
|
path = redirect (me, path);
|
1998-08-25 20:00:16 +04:00
|
|
|
return utime (path, times);
|
|
|
|
}
|
|
|
|
|
1998-09-27 23:27:58 +04:00
|
|
|
static int sfs_readlink (vfs *me, char *path, char *buf, int size)
|
1998-08-25 20:00:16 +04:00
|
|
|
{
|
1999-01-11 03:48:23 +03:00
|
|
|
path = redirect (me, path);
|
1998-08-25 20:00:16 +04:00
|
|
|
return readlink (path, buf, size);
|
|
|
|
}
|
|
|
|
|
1998-09-27 23:27:58 +04:00
|
|
|
static vfsid sfs_getid (vfs *me, char *path, struct vfs_stamping **parent)
|
1998-08-25 20:00:16 +04:00
|
|
|
{ /* FIXME: what should I do? */
|
|
|
|
vfs *v;
|
|
|
|
vfsid id;
|
|
|
|
struct vfs_stamping *par;
|
1999-01-10 02:08:41 +03:00
|
|
|
struct cachedfile *cur = head;
|
1998-08-25 20:00:16 +04:00
|
|
|
|
1999-01-10 02:08:41 +03:00
|
|
|
while (cur) {
|
|
|
|
if ((!strcmp( path, cur->name )) &&
|
|
|
|
(vfs_uid == cur->uid))
|
1998-08-25 20:00:16 +04:00
|
|
|
break;
|
1999-01-10 02:08:41 +03:00
|
|
|
cur = cur->next;
|
1998-08-25 20:00:16 +04:00
|
|
|
}
|
1999-01-10 02:08:41 +03:00
|
|
|
if (!cur)
|
1998-08-25 20:00:16 +04:00
|
|
|
vfs_die( "sfs_getid of noncached thingie?" );
|
|
|
|
|
|
|
|
*parent = NULL;
|
|
|
|
|
|
|
|
{
|
1999-01-21 01:01:11 +03:00
|
|
|
char *path2 = g_strdup (path);
|
1999-04-07 21:37:36 +04:00
|
|
|
v = vfs_split (path2, NULL, NULL); /* Strip suffix which led to this being sfs */
|
|
|
|
v = vfs_split (path2, NULL, NULL); /* ... and learn whoever was the parent system */
|
1998-09-27 23:27:58 +04:00
|
|
|
id = (*v->getid) (v, path2, &par);
|
1999-01-21 01:01:11 +03:00
|
|
|
g_free (path2);
|
1998-08-25 20:00:16 +04:00
|
|
|
}
|
|
|
|
|
|
|
|
if (id != (vfsid)-1) {
|
1999-01-21 01:01:11 +03:00
|
|
|
*parent = g_new (struct vfs_stamping, 1);
|
1998-08-25 20:00:16 +04:00
|
|
|
(*parent)->v = v;
|
|
|
|
(*parent)->id = id;
|
|
|
|
(*parent)->parent = par;
|
|
|
|
(*parent)->next = NULL;
|
|
|
|
}
|
|
|
|
return (vfsid) cur;
|
|
|
|
}
|
|
|
|
|
|
|
|
static void sfs_free (vfsid id)
|
|
|
|
{
|
1998-09-14 12:14:31 +04:00
|
|
|
struct cachedfile *which = (struct cachedfile *) id;
|
1999-01-10 02:08:41 +03:00
|
|
|
struct cachedfile *cur, *prev;
|
1998-08-25 20:00:16 +04:00
|
|
|
|
1999-01-10 02:08:41 +03:00
|
|
|
for (cur = head, prev = 0; cur && cur != which; prev = cur, cur = cur->next)
|
|
|
|
;
|
|
|
|
if (!cur)
|
1998-09-14 12:14:31 +04:00
|
|
|
vfs_die( "Free of thing which is unknown to me\n" );
|
1999-01-10 02:08:41 +03:00
|
|
|
unlink (cur->cache);
|
|
|
|
|
|
|
|
if (prev)
|
|
|
|
prev->next = cur->next;
|
|
|
|
else
|
|
|
|
head = cur->next;
|
1998-08-25 20:00:16 +04:00
|
|
|
}
|
|
|
|
|
1998-09-27 23:27:58 +04:00
|
|
|
static void sfs_fill_names (vfs *me, void (*func)(char *))
|
1998-08-25 20:00:16 +04:00
|
|
|
{
|
|
|
|
struct cachedfile *cur = head;
|
|
|
|
|
|
|
|
while (cur){
|
|
|
|
(*func)(cur->name);
|
|
|
|
cur = cur->next;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
static int sfs_nothingisopen (vfsid id)
|
|
|
|
{
|
1998-12-31 18:54:49 +03:00
|
|
|
/* FIXME: Investigate whether have to guard this like in
|
|
|
|
the other VFSs (see fd_usage in extfs) -- Norbert */
|
|
|
|
return 1;
|
1998-08-25 20:00:16 +04:00
|
|
|
}
|
|
|
|
|
1998-09-27 23:27:58 +04:00
|
|
|
static char *sfs_getlocalcopy (vfs *me, char *path)
|
1998-08-25 20:00:16 +04:00
|
|
|
{
|
1999-01-11 03:48:23 +03:00
|
|
|
path = redirect (me, path);
|
1999-01-21 01:01:11 +03:00
|
|
|
return g_strdup (path);
|
1998-08-25 20:00:16 +04:00
|
|
|
}
|
|
|
|
|
1999-11-11 17:23:40 +03:00
|
|
|
static int sfs_ungetlocalcopy (vfs *me, char *path, char *local, int has_changed)
|
1998-08-25 20:00:16 +04:00
|
|
|
{
|
1999-11-11 17:23:40 +03:00
|
|
|
g_free(local);
|
|
|
|
return 0;
|
1998-08-25 20:00:16 +04:00
|
|
|
}
|
|
|
|
|
1998-09-29 20:01:16 +04:00
|
|
|
static int sfs_init (vfs *me)
|
1998-08-25 20:00:16 +04:00
|
|
|
{
|
1999-01-11 03:48:23 +03:00
|
|
|
FILE *cfg = fopen (LIBDIR "extfs/sfs.ini", "r");
|
|
|
|
|
|
|
|
if (!cfg){
|
|
|
|
fprintf (stderr, "Warning: " LIBDIR "extfs/sfs.ini not found\n");
|
1998-09-27 23:27:58 +04:00
|
|
|
return 0;
|
1998-08-25 20:00:16 +04:00
|
|
|
}
|
|
|
|
|
|
|
|
sfs_no = 0;
|
1999-01-11 03:48:23 +03:00
|
|
|
while (sfs_no < MAXFS){
|
1998-08-25 20:00:16 +04:00
|
|
|
char key[256];
|
|
|
|
char *c, *semi = NULL, flags = 0;
|
|
|
|
int i;
|
|
|
|
|
1999-01-11 03:48:23 +03:00
|
|
|
if (!fgets (key, 250, cfg))
|
1998-08-25 20:00:16 +04:00
|
|
|
break;
|
|
|
|
|
|
|
|
if (*key == '#')
|
|
|
|
continue;
|
|
|
|
|
1999-01-11 03:48:23 +03:00
|
|
|
for (i = 0; i < strlen (key); i++)
|
|
|
|
if ((key[i]==':') || (key[i]=='/')){
|
|
|
|
semi = key+i;
|
|
|
|
if (key [i] == '/'){
|
|
|
|
key [i] = 0;
|
|
|
|
flags |= F_FULLMATCH;
|
|
|
|
}
|
|
|
|
break;
|
|
|
|
}
|
1998-08-25 20:00:16 +04:00
|
|
|
|
1999-01-11 03:48:23 +03:00
|
|
|
if (!semi){
|
|
|
|
fprintf (stderr, "Warning: Invalid line %s in sfs.ini.\n", key);
|
1998-08-25 20:00:16 +04:00
|
|
|
continue;
|
|
|
|
}
|
|
|
|
|
|
|
|
c = semi + 1;
|
|
|
|
while ((*c != ' ') && (*c != 9)) {
|
|
|
|
switch (*c) {
|
|
|
|
case '1': flags |= F_1; break;
|
|
|
|
case '2': flags |= F_2; break;
|
|
|
|
case 'R': flags |= F_NOLOCALCOPY; break;
|
|
|
|
default:
|
1999-01-11 03:48:23 +03:00
|
|
|
fprintf (stderr, "Warning: Invalid flag %c in sfs.ini line %s.\n", *c, key);
|
1998-08-25 20:00:16 +04:00
|
|
|
}
|
|
|
|
c++;
|
|
|
|
}
|
|
|
|
c++;
|
|
|
|
*(semi+1) = 0;
|
1999-01-11 03:48:23 +03:00
|
|
|
if ((semi = strchr (c, '\n')))
|
1998-08-25 20:00:16 +04:00
|
|
|
*semi = 0;
|
|
|
|
|
1999-01-21 01:01:11 +03:00
|
|
|
sfs_prefix [sfs_no] = g_strdup (key);
|
|
|
|
sfs_command [sfs_no] = g_strdup (c);
|
1998-08-25 20:00:16 +04:00
|
|
|
sfs_flags [sfs_no] = flags;
|
|
|
|
sfs_no++;
|
|
|
|
}
|
1999-01-11 03:48:23 +03:00
|
|
|
fclose (cfg);
|
1998-09-27 23:27:58 +04:00
|
|
|
return 1;
|
1998-08-25 20:00:16 +04:00
|
|
|
}
|
|
|
|
|
1999-01-11 03:48:23 +03:00
|
|
|
static void
|
|
|
|
sfs_done (vfs *me)
|
1998-09-14 12:14:31 +04:00
|
|
|
{
|
|
|
|
int i;
|
1999-01-11 03:48:23 +03:00
|
|
|
|
|
|
|
for (i = 0; i < sfs_no; i++){
|
1999-01-21 01:01:11 +03:00
|
|
|
g_free (sfs_prefix [i]);
|
|
|
|
g_free (sfs_command [i]);
|
1998-09-14 12:14:31 +04:00
|
|
|
sfs_prefix [i] = sfs_command [i] = NULL;
|
|
|
|
}
|
|
|
|
sfs_no = 0;
|
|
|
|
}
|
|
|
|
|
1999-01-11 03:48:23 +03:00
|
|
|
static int
|
|
|
|
sfs_which (vfs *me, char *path)
|
1998-08-25 20:00:16 +04:00
|
|
|
{
|
|
|
|
int i;
|
|
|
|
|
|
|
|
for (i = 0; i < sfs_no; i++)
|
|
|
|
if (sfs_flags [i] & F_FULLMATCH) {
|
|
|
|
if (!strcmp (path, sfs_prefix [i]))
|
|
|
|
return i;
|
|
|
|
} else
|
1999-01-11 03:48:23 +03:00
|
|
|
if (!strncmp (path, sfs_prefix [i], strlen (sfs_prefix [i])))
|
1998-08-25 20:00:16 +04:00
|
|
|
return i;
|
|
|
|
|
|
|
|
|
|
|
|
return -1;
|
|
|
|
}
|
1998-09-27 23:27:58 +04:00
|
|
|
|
1998-10-13 02:07:53 +04:00
|
|
|
vfs vfs_sfs_ops = {
|
1998-09-27 23:27:58 +04:00
|
|
|
NULL, /* This is place of next pointer */
|
|
|
|
"Signle file filesystems",
|
|
|
|
F_EXEC, /* flags */
|
|
|
|
NULL, /* prefix */
|
|
|
|
NULL, /* data */
|
|
|
|
0, /* errno */
|
|
|
|
sfs_init,
|
|
|
|
sfs_done,
|
|
|
|
sfs_fill_names,
|
|
|
|
sfs_which,
|
|
|
|
|
|
|
|
sfs_open,
|
|
|
|
local_close,
|
|
|
|
local_read,
|
|
|
|
NULL,
|
|
|
|
|
|
|
|
NULL,
|
|
|
|
NULL,
|
|
|
|
NULL,
|
|
|
|
NULL,
|
|
|
|
NULL,
|
|
|
|
|
|
|
|
sfs_stat,
|
|
|
|
sfs_lstat,
|
|
|
|
local_fstat,
|
|
|
|
|
|
|
|
sfs_chmod,
|
|
|
|
sfs_chown,
|
|
|
|
sfs_utime,
|
|
|
|
|
|
|
|
sfs_readlink,
|
|
|
|
NULL,
|
|
|
|
NULL,
|
|
|
|
NULL,
|
|
|
|
|
|
|
|
NULL,
|
|
|
|
NULL,
|
|
|
|
local_errno,
|
|
|
|
local_lseek,
|
|
|
|
NULL,
|
|
|
|
|
|
|
|
sfs_getid,
|
|
|
|
sfs_nothingisopen,
|
|
|
|
sfs_free,
|
|
|
|
|
|
|
|
sfs_getlocalcopy,
|
|
|
|
sfs_ungetlocalcopy,
|
|
|
|
|
|
|
|
NULL,
|
|
|
|
NULL,
|
|
|
|
NULL,
|
|
|
|
NULL
|
1998-10-13 02:07:53 +04:00
|
|
|
|
1998-09-27 23:27:58 +04:00
|
|
|
#ifdef HAVE_MMAP
|
1998-10-13 02:07:53 +04:00
|
|
|
,local_mmap,
|
|
|
|
local_munmap
|
1998-09-27 23:27:58 +04:00
|
|
|
#endif
|
|
|
|
};
|
|
|
|
|