[wp-trac] Re: [WordPress Trac] #10170: File Permissions on Creation (Plugin but might be Theme as well)

WordPress Trac wp-trac at lists.automattic.com
Sun Jun 28 11:53:38 GMT 2009


#10170: File Permissions on Creation (Plugin but might be Theme as well)
-------------------------------------+--------------------------------------
 Reporter:  hakre                    |        Owner:  dd32    
     Type:  defect (bug)             |       Status:  reopened
 Priority:  normal                   |    Milestone:  2.8.1   
Component:  Filesystem               |      Version:  2.8     
 Severity:  normal                   |   Resolution:          
 Keywords:  has-patch tested commit  |  
-------------------------------------+--------------------------------------

Comment(by hakre):

 Replying to [comment:13 dd32]:
 > IMO, Theres no need to add verbose comments like that. A simple "Octal
 representation of a unix permission" would fit better.
 Jup, that was copied over, I saw that after the upload of the patch,
 that's too much of it. Sorry for that. It's way much too big at all.

 > I'm adding a patch which strips out the permission property, since its
 useless, And makes the permission a required arguement of ::chmod() (I
 mean, You call it to be very specific, chmod to THIS permission set). The
 method setDefaultPermission() has never really been used by WP, nor is it
 actually useable.. So.. removed that as well.
 You know that better then me. If it is not used, remove it.

 > My patch needs testing, As i've not actually tested it.
 Could only review it:

  *  function mkdir(): ''if( ! $chmod )'' with default of ''$chmod =
 false'' is unable for a $chmod = 0000; (int 0 as octal representation).
 that is a valid permission in unix, right? so better to comapre against
 NULL again (=== null)
  * TYPO: ''return false; //Prevent '''tihs''' function looping again.'' in
 line 213.

 I have your patch on my list for testing.

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/10170#comment:15>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list