Hello AST Users,
I am looking for a kind of 'dup(2)' but for SFIO streams.
What does:
Sfio_t *curfp = sfstdin ;
Sfio_t *newfp ;
newfp = sfswap(curfp,NULL) ;
do -- sematics wise?
Can this be construed as giving me a new SFIO stream, but one that is
both new and a duplicate of the existing one? The SFIO(3) manual page
seems to indicate that this is a sort of 'dup' for SFIO streams but it
does not appear to properly perform w/ those semantics. More specifically,
closing the "new" stream seems to close the old one also. Is that
correct behavior?
I am using this within a KSH built-in and it seems to do some strange
things if the new stream is closed.
Thanks for any information,
David Morano
[email protected]
_______________________________________________
ast-users mailing list
[email protected]
https://mailman.research.att.com/mailman/listinfo/ast-users