2013/8/1 Glenn Fowler <[email protected]>:
[snip]
>
> its in src/lib/libast/path/pathopen.c which unifies all of the
> /dev/ and /proc/<pid>/<fd>/ intercepts in one place
> my bad
> try this patch
> (your line numbers will differ because mast source doesn't have the copyright 
> comment)
>
> --- .../path/pathopen.c Tue Jul 23 14:51:50 2013
> +++ path/pathopen.c     Thu Aug  1 14:55:47 2013
> @@ -162,7 +162,12 @@
>                                 return 1;
>                         }
>
> -                       /* F_GETFL must match oflags */
> +                       /* a trailing path component means dev.fd must be a 
> directory */
> +
> +                       if (b[dev.path.offset])
> +                               return openat(dev.fd, b + dev.path.offset, 
> oflags, mode);
> +
> +                       /* the path boils down to just dev.fd -- F_GETFL must 
> match oflags */
>
>                         if (!(f & O_RDWR) && (f & O_ACCMODE) != (oflags & 
> O_ACCMODE))
>                         {

Thanks... the patch seems to fix the issue on SuSE
12.3/Linux/AMD64/64bit... I'll test more platforms (Solaris) later
today...
... and if I find time I write a "directoryfd.sh" test module to cover
this area...

----

Bye,
Roland

-- 
  __ .  . __
 (o.\ \/ /.o) [email protected]
  \__\/\/__/  MPEG specialist, C&&JAVA&&Sun&&Unix programmer
  /O /==\ O\  TEL +49 641 3992797
 (;O/ \/ \O;)
_______________________________________________
ast-developers mailing list
[email protected]
http://lists.research.att.com/mailman/listinfo/ast-developers

Reply via email to