New submission from dobbelaj <jeroen.dobbela...@gmail.com>:

The 'os.stat' method on windows seems to be hardcoded to check the file name 
extension when computing the 'executable permission flag' (st_mode).

(See Modules/posixmodule.c:  win32_stat and win32_wstat)

Currently, it checks for : 
 '.bat', '.cmd', '.exe', '.com'

As dynamic libraries also must be executable on window, t should also check for 
: 
 '.dll'

It would be even better if the actual 'read and execute' permission is returned.

----------
components: Windows
messages: 126004
nosy: jeroen.dobbelaere
priority: normal
severity: normal
status: open
title: os.stat(filepath).st_mode gives wrong 'executable permission' result
type: behavior
versions: Python 2.7

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue10888>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to