Prev Next

class MntSrv (rfc1094.MOUNTPROG_1, HostAccessControl):
"""See RFC1094."""
deliberately_unimplemented = ['MOUNTPROC_EXPORT', 'MOUNTPROC_UMNTALL',
'MOUNTPROC_UMNT', 'MOUNTPROC_DUMP']
def __init__ (self, fs):
self.fs = fs
rfc1094.MOUNTPROG_1.__init__ (self)
def MOUNTPROC_NULL (self):
return None

def MOUNTPROC_MNT (self, dirpath):
ret = rfc1094.fhstatus ()
fh = self.fs.mount (dirpath)
if fh == None:
ret.status = rfc1094.NFSERR_NOENT
else:
ret.status = rfc1094.NFS_OK
ret._data = fh
return ret