Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fcntl footnote about O_SHLOCK and O_EXLOCK is misleading #50444

Closed
bitdancer opened this issue Jun 4, 2009 · 2 comments
Closed

fcntl footnote about O_SHLOCK and O_EXLOCK is misleading #50444

bitdancer opened this issue Jun 4, 2009 · 2 comments
Assignees
Labels
docs Documentation in the Doc dir easy type-bug An unexpected behavior, bug, or error

Comments

@bitdancer
Copy link
Member

BPO 6194
Nosy @birkenfeld, @bitdancer

Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.

Show more details

GitHub fields:

assignee = 'https://github.com/birkenfeld'
closed_at = <Date 2009-06-08.13:35:02.473>
created_at = <Date 2009-06-04.21:38:31.803>
labels = ['easy', 'type-bug', 'docs']
title = 'fcntl footnote about O_SHLOCK and O_EXLOCK is misleading'
updated_at = <Date 2009-06-08.13:35:02.471>
user = 'https://github.com/bitdancer'

bugs.python.org fields:

activity = <Date 2009-06-08.13:35:02.471>
actor = 'georg.brandl'
assignee = 'georg.brandl'
closed = True
closed_date = <Date 2009-06-08.13:35:02.473>
closer = 'georg.brandl'
components = ['Documentation']
creation = <Date 2009-06-04.21:38:31.803>
creator = 'r.david.murray'
dependencies = []
files = []
hgrepos = []
issue_num = 6194
keywords = ['easy']
message_count = 2.0
messages = ['88904', '89079']
nosy_count = 2.0
nosy_names = ['georg.brandl', 'r.david.murray']
pr_nums = []
priority = 'low'
resolution = 'fixed'
stage = 'needs patch'
status = 'closed'
superseder = None
type = 'behavior'
url = 'https://bugs.python.org/issue6194'
versions = ['Python 2.6', 'Python 3.0', 'Python 3.1', 'Python 2.7']

@bitdancer
Copy link
Member Author

At the bottom of http://docs.python.org/library/fcntl.html there is a
"see also" section for the os module that says:

If the locking flags O_SHLOCK and O_EXLOCK are present in the os

module, the os.open() function provides a more platform-independent
alternative to the lockf() and flock() functions.

However, those flags are documented as being "unix only" (ie: no
windows), and in fact Linux does not support them. Alan Cox rejected
support for them back in 2000 according to this linux kernel posting:

http://lkml.indiana.edu/hypermail/linux/kernel/0005.1/1309.html

so it doesn't seem likely linux will ever support them.

Thus, to say that they provide a "more platform independent-alternative"
would appear to be false, since they appear to only be supported on BSD
and derivitives.

@bitdancer bitdancer added docs Documentation in the Doc dir easy type-bug An unexpected behavior, bug, or error labels Jun 4, 2009
@birkenfeld
Copy link
Member

Thanks, fixed in r73294.

@ezio-melotti ezio-melotti transferred this issue from another repository Apr 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs Documentation in the Doc dir easy type-bug An unexpected behavior, bug, or error
Projects
None yet
Development

No branches or pull requests

2 participants