2 Copyright © 1995-2012, The AROS Development Team. All rights reserved.
6 #include <aros/symbolsets.h>
10 #include LC_LIBDEFS_FILE
12 /*****************************************************************************
28 umask is currently remembered but not used in any function
38 ******************************************************************************/
40 struct PosixCIntBase
*PosixCBase
=
41 (struct PosixCIntBase
*)__aros_getbase_PosixCBase();
42 mode_t oumask
= PosixCBase
->umask
;
44 PosixCBase
->umask
= numask
;
49 static int __umask_init(struct PosixCIntBase
*PosixCBase
)
51 struct PosixCIntBase
*pPosixCBase
;
53 pPosixCBase
= __GM_GetBaseParent(PosixCBase
);
55 /* TODO: Implement umask() properly
56 Currently information is not used in any of the related functions
59 /* Child of exec*()/vfork() functions inherit umask of parent */
60 if (pPosixCBase
&& (pPosixCBase
->flags
& (VFORK_PARENT
| EXEC_PARENT
)))
61 PosixCBase
->umask
= pPosixCBase
->umask
;
63 PosixCBase
->umask
= S_IWGRP
|S_IWOTH
;
68 ADD2OPENLIB(__umask_init
, 0);