Making a gpg library
raf
raf at comdyn.com.au
Thu Oct 26 12:14:53 CEST 2000
David Champion wrote:
> On 2000.10.25, in <20001025145256.Y22713 at gnupg.de>,
> "Werner Koch" <wk at gnupg.org> wrote:
> > On Wed, 25 Oct 2000, Florian Weimer wrote:
> >
> > > I think you can emulate /dev/fd this way: If you encounter /dev/fd/NR
> > > on the command line, just do fdopen(NR, some_mode).
> >
> > That should work and is similar to the thing gawk does.
> >
> > HPUX, Solaris, AIX, fooix folks please complain *now* or be quite
> > forever on this topic :-)
>
> I'm mainly a Solaris person. We have /dev/fd/*, but I still think that
> while clever, this is a *highly* unexpected way to deal with fd's (that
> is, "unintuitive"). It's a neat trick to support, but I don't think it
> should be relied upon as the sole means of fd access.
>
> My gut feeling is that file paths should actually exist, not just be
> ghosted in application software.
>
> It's also conceivable that some "innovative" vendor would come by with
> an alternate path for a fd filesystem -- say, /dev/fds/*. That would
> certainly confuse matters on that platform.
>
> --
> -D. dgc at uchicago.edu NSIT University of Chicago
but wouldn't it just work? i.e. gpg doesn't recognise it as /dev/fd/*
(because it isn't) so it just does the normal thing of opening the
"file" /dev/fds/* instead which is the file descriptor.
raf
More information about the Gnupg-devel
mailing list