Merge from vendor branch TNF:
[pkgsrc.git] / security / sfs / patches / patch-bn
1 $NetBSD$
2
3 --- ./sfsrwsd/filesrv.C.orig    2002-08-21 14:54:50.000000000 +0100
4 +++ ./sfsrwsd/filesrv.C
5 @@ -358,7 +358,7 @@ bool
6  filesrv::fixarg (svccb *sbp, reqstate *rqsp)
7  {
8    fh3trans fht (fh3trans::DECODE, fhkey);
9 -  if (!nfs3_transarg (fht, sbp->template getarg<void> (), sbp->proc ())) {
10 +  if (!nfs3_transarg (fht, sbp->getarg<void> (), sbp->proc ())) {
11      nfs3exp_err (sbp, nfsstat3 (fht.err));
12      return false;
13    }
14 @@ -378,7 +378,7 @@ filesrv::fixarg (svccb *sbp, reqstate *r
15     * creating multiple mount points for each server.  Is this bad? */
16    if (!sbp->getaui ()
17        && !anon_checkperm (sbp, fsp->options,
18 -                         *sbp->template getarg<nfs_fh3> () == fsp->fh_root))
19 +                         *sbp->getarg<nfs_fh3> () == fsp->fh_root))
20      return false;
21  #else
22    /* The other option is to disallow this.  Then commands like "ls
23 @@ -386,7 +386,7 @@ filesrv::fixarg (svccb *sbp, reqstate *r
24    if (!sbp->getaui ()
25        && !anon_checkperm (sbp, fsp->options,
26                           (fsp == fstab.base ()
27 -                          && (*sbp->template getarg<nfs_fh3> ()
28 +                          && (*sbp->getarg<nfs_fh3> ()
29                                == fsp->fh_root))))
30      return false;
31  #endif
32 @@ -394,7 +394,7 @@ filesrv::fixarg (svccb *sbp, reqstate *r
33    switch (sbp->proc ()) {
34    case NFSPROC3_LOOKUP:
35      {
36 -      diropargs3 *doa = sbp->template getarg<diropargs3> ();
37 +      diropargs3 *doa = sbp->getarg<diropargs3> ();
38        if (doa->name == ".." && doa->dir == fsp->fh_root) {
39         if (!getfsno (fsp)) {
40           nfs3exp_err (sbp, NFS3ERR_ACCES);
41 @@ -411,7 +411,7 @@ filesrv::fixarg (svccb *sbp, reqstate *r
42    case NFSPROC3_READDIR:
43    case NFSPROC3_READDIRPLUS:
44      {
45 -      nfs_fh3 *rpa = sbp->template getarg<nfs_fh3> ();
46 +      nfs_fh3 *rpa = sbp->getarg<nfs_fh3> ();
47        if (*rpa == fsp->fh_root)
48         rqsp->rootfh = true;
49        break;