apr-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From wr...@apache.org
Subject svn commit: r425620 - /apr/apr/trunk/file_io/win32/filestat.c
Date Wed, 26 Jul 2006 04:56:35 GMT
Author: wrowe
Date: Tue Jul 25 21:56:35 2006
New Revision: 425620

URL: http://svn.apache.org/viewvc?rev=425620&view=rev
Log:

  With this patch, the finfo.protection includes the rights for the current
  user, and the rights for his/her primary group (plus world/Everyone), when
  requested by the wanted bits of either user/group id, or user/group prot.

Submitted by: Andreas Magnusson <andreas.ch.magnusson home.se>
Message-ID:   <dqt4a6$b6n$1@sea.gmane.org>

Reviewed by: wrowe, D.J. Heap <djheap gmail.com>  


Modified:
    apr/apr/trunk/file_io/win32/filestat.c

Modified: apr/apr/trunk/file_io/win32/filestat.c
URL: http://svn.apache.org/viewvc/apr/apr/trunk/file_io/win32/filestat.c?rev=425620&r1=425619&r2=425620&view=diff
==============================================================================
--- apr/apr/trunk/file_io/win32/filestat.c (original)
+++ apr/apr/trunk/file_io/win32/filestat.c Tue Jul 25 21:56:35 2006
@@ -242,8 +242,8 @@
             }
             rv = GetNamedSecurityInfoW(wfile + fix, 
                                  SE_FILE_OBJECT, sinf,
-                                 ((wanted & APR_FINFO_USER) ? &user : NULL),
-                                 ((wanted & APR_FINFO_GROUP) ? &grp : NULL),
+                                 ((wanted & (APR_FINFO_USER | APR_FINFO_UPROT)) ? &user
: NULL),
+                                 ((wanted & (APR_FINFO_GROUP | APR_FINFO_GPROT)) ? &grp
: NULL),
                                  ((wanted & APR_FINFO_PROT) ? &dacl : NULL),
                                  NULL, &pdesc);
             if (fix == 6)
@@ -252,15 +252,15 @@
         else if (whatfile == MORE_OF_FSPEC)
             rv = GetNamedSecurityInfoA((char*)ufile, 
                                  SE_FILE_OBJECT, sinf,
-                                 ((wanted & APR_FINFO_USER) ? &user : NULL),
-                                 ((wanted & APR_FINFO_GROUP) ? &grp : NULL),
+                                 ((wanted & (APR_FINFO_USER | APR_FINFO_UPROT)) ? &user
: NULL),
+                                 ((wanted & (APR_FINFO_GROUP | APR_FINFO_GPROT)) ? &grp
: NULL),
                                  ((wanted & APR_FINFO_PROT) ? &dacl : NULL),
                                  NULL, &pdesc);
         else if (whatfile == MORE_OF_HANDLE)
             rv = GetSecurityInfo((HANDLE)ufile, 
                                  SE_FILE_OBJECT, sinf,
-                                 ((wanted & APR_FINFO_USER) ? &user : NULL),
-                                 ((wanted & APR_FINFO_GROUP) ? &grp : NULL),
+                                 ((wanted & (APR_FINFO_USER | APR_FINFO_UPROT)) ? &user
: NULL),
+                                 ((wanted & (APR_FINFO_GROUP | APR_FINFO_GPROT)) ? &grp
: NULL),
                                  ((wanted & APR_FINFO_PROT) ? &dacl : NULL),
                                  NULL, &pdesc);
         else



Mime
View raw message