Path: utzoo!attcan!uunet!lll-winken!ames!haven!adm!xadmx!mark@spider.co.uk From: mark@spider.co.uk (Mark Valentine) Newsgroups: comp.unix.questions Subject: Question about dup() Message-ID: <19538@adm.BRL.MIL> Date: 10 May 89 11:20:19 GMT Sender: news@adm.BRL.MIL Lines: 19 I came across the following code fragment, and was wondering about its history... It's not mentioned in any of the manuals I've looked at. #define DUPFLG 0100 ... dup(f1 | DUPFLG, f2); There was some parallel code (the other half of an #ifdef RES) which used a F_GETFD/F_DUPFD/F_SETFD sequence instead, so I guess that this must be somebody's way of saving the close-on-exec flag across a dup. Can anyone offer some enlightenment? Mark. __ Mark Valentine, Spider Systems Limited, Edinburgh, UK. /\oo/\