From: solar Date: Wed, 23 Jun 2010 05:17:46 +0000 (+0000) Subject: New file permissions. X-Git-Url: https://git.gag.com/?a=commitdiff_plain;h=fa9a046dd93a1ef19f658671fb7c5d2c63500141;p=fw%2Fpdclib New file permissions. git-svn-id: https://srv7.svn-repos.de/dev34/pdclib/trunk@427 546481bc-9713-0410-bf18-d3337bbf4a3e --- diff --git a/platform/example/functions/_PDCLIB/open.c b/platform/example/functions/_PDCLIB/open.c index f0379ba..133b729 100644 --- a/platform/example/functions/_PDCLIB/open.c +++ b/platform/example/functions/_PDCLIB/open.c @@ -26,8 +26,6 @@ int _PDCLIB_open( char const * const filename, unsigned int mode ) { /* This is an example implementation of _PDCLIB_open() fit for use with POSIX kernels. - FIXME: The permissions of newly created files should not be hardcoded - here. */ int osmode; switch ( mode & ( _PDCLIB_FREAD | _PDCLIB_FWRITE | _PDCLIB_FAPPEND | _PDCLIB_FRW ) ) @@ -56,7 +54,7 @@ int _PDCLIB_open( char const * const filename, unsigned int mode ) int rc; if ( osmode & O_CREAT ) { - rc = open( filename, osmode, S_IRUSR | S_IWUSR ); + rc = open( filename, osmode, S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH | S_IWOTH ); } else {