code: mafs

ref: 80e6c118c65b013bde24f8b9c95881c0e3a73d3e
dir: /dat.c/

View raw version
#include	"u.h"
#include	"libc.h"
#include	"dat.h"

char*	tagnames[] =
{
	[Tblank]	"Tblank",
	[Tdentry]	"Tdentry",
	[Tdata]		"Tdata",
	[Tind0]		"Tind0",
	[Tind1]		"Tind1",
	[Tind2]		"Tind2",
	[Tind3]		"Tind3",
	[Tind4]		"Tind4",

	/* add more Tind tags here ... */
};

char	*errstring[MAXERR] =
{
	[Eaccess]	"access permission denied",
	[Ealloc]	"phase error -- directory entry not allocated",
	[Eauth]		"authentication failed",
	[Eauthmsg]	"kfs: authentication not required",
	[Ebadname]	"bad name",
	[Ebadspc]	"attach -- bad specifier",
	[Ebadu]		"attach -- privileged user",
	[Ebroken]	"close/read/write -- lock is broken",
	[Echar]		"bad character in directory name",
	[Econvert]	"protocol botch",
	[Ecount]	"read/write -- count too big",
	[Edir1]		"walk -- in a non-directory",
	[Edir2]		"create -- in a non-directory",
	[Edirty]	"dirty filesystem",
	[Edot]		"create -- . and .. illegal names",
	[Eempty]	"remove -- directory not empty",
	[Eentry]	"directory entry not found",
	[Eexist]	"create -- file exists",
	[Efid]		"unknown fid",
	[Efidinuse]	"fid already in use",
	[Efull]		"file system full",
	[Einval]	"invalid operation",
	[Elocked]	"open/create -- file is locked",
	[Emode]		"open/create -- unknown mode",
	[Ename]		"create/wstat -- bad character in file name",
	[Enomem]	"no memory",
	[Enotd]		"wstat -- attempt to change directory",
	[Enotdir]	"not a directory",
	[Enotg]		"wstat -- not in group",
	[Enotl]		"wstat -- attempt to change length",
	[Enotm]		"wstat -- unknown type/mode",
	[Enotu]		"wstat -- not owner",
	[Eoffset]	"read/write -- offset negative",
	[Eopen]		"read/write -- on non open fid",
	[Eperm]		"no permission",
	[Ephase]	"phase error -- cannot happen",
	[Eqid]		"phase error -- qid does not match",
	[Eqidmode]	"wstat -- qid.type/dir.mode mismatch",
	[Eronly]	"file system read only",
	[Ersc]	"it's russ's fault.  bug him.",
	[Eshutdown]	"m[]afs shutting down",
	[Esystem]	"m[a]fs system error",
	[Etoolong]	"name too long",
	[Einvusers]	"invalid users contents",
	[Enousers]	"no users",
	[Ewalk]		"walk -- too many (system wide)",
};