X-Git-Url: https://git.decadent.org.uk/gitweb/?p=nfs-utils.git;a=blobdiff_plain;f=utils%2Fmountd%2Fcache.c;h=0296f4efd19f187ea20bcfcf1d785e8a05f29bc3;hp=5285e10d8fbcb85eb199d7fea01c29cc6a19e63d;hb=e6b281c7a032ccb2a0f71ef983e50bf80b261dc1;hpb=ac5b03be829b4c9369ebfb07a688308721103228 diff --git a/utils/mountd/cache.c b/utils/mountd/cache.c index 5285e10..0296f4e 100644 --- a/utils/mountd/cache.c +++ b/utils/mountd/cache.c @@ -381,6 +381,12 @@ void cache_export(nfs_export *exp) { FILE *f; + if (exp->m_export.e_maptype != CLE_MAP_IDENT) { + xlog(L_ERROR, "%s: unsupported mapping; kernel supports only 'identity' (default)", + exp->m_export.m_path); + return; + } + f = fopen("/proc/net/rpc/auth.unix.ip/channel", "w"); if (!f) return; @@ -429,7 +435,7 @@ cache_get_filehandle(nfs_export *exp, int len, char *p) if (failed) return NULL; memset(fh.fh_handle, 0, sizeof(fh.fh_handle)); - fh.fh_size = qword_get(&bp, fh.fh_handle, NFS3_FHSIZE); + fh.fh_size = qword_get(&bp, (char *)fh.fh_handle, NFS3_FHSIZE); return &fh; }