/*
- * $Id: unix.c,v 1.53 2009-10-02 09:32:40 franklahm Exp $
+ * $Id: unix.c,v 1.54 2009-10-13 22:55:37 didg Exp $
*
* Copyright (c) 1990,1993 Regents of The University of Michigan.
* All Rights Reserved. See COPYRIGHT.
/*
* Get the free space on a partition.
*/
-int ustatfs_getvolspace( vol, bfree, btotal, bsize )
-const struct vol *vol;
-VolSpace *bfree, *btotal;
-u_int32_t *bsize;
+int ustatfs_getvolspace(const struct vol *vol, VolSpace *bfree, VolSpace *btotal, u_int32_t *bsize)
{
VolSpace maxVolSpace = (~(VolSpace)0);
return( AFP_OK );
}
-static int utombits( bits )
-mode_t bits;
+static int utombits(mode_t bits)
{
int mbits;
/* --------------------------------
cf AFP 3.0 page 63
*/
-void utommode( stat, ma )
-struct stat *stat;
-struct maccess *ma;
+void utommode(struct stat *stat, struct maccess *ma)
{
mode_t mode;
*
* dir parameter is used by AFS
*/
-void accessmode( path, ma, dir, st )
-char *path;
-struct maccess *ma;
-struct dir *dir _U_;
-struct stat *st;
+void accessmode(char *path, struct maccess *ma, struct dir *dir _U_, struct stat *st)
{
struct stat sb;
#endif
}
-int gmem( gid )
-const gid_t gid;
+int gmem(const gid_t gid)
{
int i;
return( 0 );
}
-static mode_t mtoubits( bits )
-u_char bits;
+static mode_t mtoubits(u_char bits)
{
mode_t mode;
and from AFP 3.0 spec page 63
the mac mode should be save somewhere
*/
-mode_t mtoumode( ma )
-struct maccess *ma;
+mode_t mtoumode(struct maccess *ma)
{
mode_t mode;
#define EXEC_MODE (S_IXGRP | S_IXUSR | S_IXOTH)
-int setdeskmode( mode )
-const mode_t mode;
+int setdeskmode(const mode_t mode)
{
char wd[ MAXPATHLEN + 1];
struct stat st;
}
/* --------------------- */
-int setfilunixmode (vol, path, mode)
-const struct vol *vol;
-struct path* path;
-mode_t mode;
+int setfilunixmode (const struct vol *vol, struct path* path, mode_t mode)
{
if (!path->st_valid) {
of_stat(path);
/* --------------------- */
-int setdirunixmode( vol, name, mode )
-const struct vol *vol;
-const char *name;
-mode_t mode;
+int setdirunixmode(const struct vol *vol, const char *name, mode_t mode)
{
int dropbox = (vol->v_flags & AFPVOL_DROPBOX);
}
/* --------------------- */
-int setdirmode( vol, name, mode )
-const struct vol *vol;
-const char *name;
-mode_t mode;
+int setdirmode(const struct vol *vol, const char *name, mode_t mode)
{
struct stat st;
struct dirent *dirp;
}
/* ----------------------------- */
-int setdeskowner( uid, gid )
-const uid_t uid;
-const gid_t gid;
+int setdeskowner(const uid_t uid, const gid_t gid)
{
char wd[ MAXPATHLEN + 1];
char modbuf[12 + 1], *m;
}
/* ----------------------------- */
-int setfilowner(vol, uid, gid, path)
-const struct vol *vol;
-const uid_t uid;
-const gid_t gid;
-struct path* path;
+int setfilowner(const struct vol *vol, const uid_t uid, const gid_t gid, struct path* path)
{
if (!path->st_valid) {
* that user/group should inherit from other, but that doesn't fit
* into the unix permission scheme. we can get around this by
* co-opting some bits. */
-int setdirowner(vol, name, uid, gid )
-const struct vol *vol;
-const char *name;
-const uid_t uid;
-const gid_t gid;
+int setdirowner(const struct vol *vol, const char *name, const uid_t uid, const gid_t gid)
{
struct stat st;
struct dirent *dirp;