Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
c0125471
Commit
c0125471
authored
Jun 28, 1996
by
Guido van Rossum
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added plock() system call.
Changed test for Windows times() emulation.
parent
cd6aab91
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
25 additions
and
1 deletion
+25
-1
Modules/posixmodule.c
Modules/posixmodule.c
+25
-1
No files found.
Modules/posixmodule.c
View file @
c0125471
...
...
@@ -1060,6 +1060,27 @@ posix_kill(self, args)
}
#endif
#ifdef HAVE_PLOCK
#ifdef HAVE_SYS_LOCK_H
#include <sys/lock.h>
#endif
static
object
*
posix_plock
(
self
,
args
)
object
*
self
;
object
*
args
;
{
int
op
;
if
(
!
getargs
(
args
,
"i"
,
&
op
))
return
NULL
;
if
(
plock
(
op
)
==
-
1
)
return
posix_error
();
INCREF
(
None
);
return
None
;
}
#endif
#ifdef HAVE_POPEN
static
object
*
posix_popen
(
self
,
args
)
...
...
@@ -1220,7 +1241,7 @@ posix_times(self, args)
(
double
)
c
/
HZ
);
}
#endif
/* HAVE_TIMES */
#if defined(
MS_WIN32) && !defined(HAVE_TIMES)
#if defined(
_MSC_VER) && _MSC_VER > 850
#define HAVE_TIMES
/* so the method table will pick it up */
static
object
*
posix_times
(
self
,
args
)
...
...
@@ -1645,6 +1666,9 @@ static struct methodlist posix_methods[] = {
#ifdef HAVE_KILL
{
"kill"
,
posix_kill
},
#endif
/* HAVE_KILL */
#ifdef HAVE_PLOCK
{
"plock"
,
posix_plock
},
#endif
/* HAVE_PLOCK */
#ifdef HAVE_POPEN
{
"popen"
,
posix_popen
,
1
},
#endif
/* HAVE_POPEN */
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment