https://github.com/python/cpython/commit/7d7eec595a47a5cd67ab420164f0059eb8b9aa28
commit: 7d7eec595a47a5cd67ab420164f0059eb8b9aa28
branch: main
author: Victor Stinner <[email protected]>
committer: vstinner <[email protected]>
date: 2024-05-13T16:03:52+02:00
summary:

gh-117873: Revert _posixshmem.shm_open() change (#118901)

files:
M Modules/_multiprocessing/clinic/posixshmem.c.h
M Modules/_multiprocessing/posixshmem.c

diff --git a/Modules/_multiprocessing/clinic/posixshmem.c.h 
b/Modules/_multiprocessing/clinic/posixshmem.c.h
index 8151f2e0b07082..a545ff4d80f067 100644
--- a/Modules/_multiprocessing/clinic/posixshmem.c.h
+++ b/Modules/_multiprocessing/clinic/posixshmem.c.h
@@ -5,7 +5,7 @@ preserve
 #if defined(HAVE_SHM_OPEN)
 
 PyDoc_STRVAR(_posixshmem_shm_open__doc__,
-"shm_open($module, path, /, flags, mode=511)\n"
+"shm_open($module, /, path, flags, mode=511)\n"
 "--\n"
 "\n"
 "Open a shared memory object.  Returns a file descriptor (integer).");
@@ -21,7 +21,7 @@ static PyObject *
 _posixshmem_shm_open(PyObject *module, PyObject *args, PyObject *kwargs)
 {
     PyObject *return_value = NULL;
-    static char *_keywords[] = {"", "flags", "mode", NULL};
+    static char *_keywords[] = {"path", "flags", "mode", NULL};
     PyObject *path;
     int flags;
     int mode = 511;
@@ -86,4 +86,4 @@ _posixshmem_shm_unlink(PyObject *module, PyObject *arg)
 #ifndef _POSIXSHMEM_SHM_UNLINK_METHODDEF
     #define _POSIXSHMEM_SHM_UNLINK_METHODDEF
 #endif /* !defined(_POSIXSHMEM_SHM_UNLINK_METHODDEF) */
-/*[clinic end generated code: output=649877fc45a65129 input=a9049054013a1b77]*/
+/*[clinic end generated code: output=74588a5abba6e36c input=a9049054013a1b77]*/
diff --git a/Modules/_multiprocessing/posixshmem.c 
b/Modules/_multiprocessing/posixshmem.c
index cc157800ade3c4..ab45e4136c7d46 100644
--- a/Modules/_multiprocessing/posixshmem.c
+++ b/Modules/_multiprocessing/posixshmem.c
@@ -32,7 +32,6 @@ module _posixshmem
 /*[clinic input]
 _posixshmem.shm_open -> int
     path: unicode
-    /
     flags: int
     mode: int = 0o777
 
@@ -45,7 +44,7 @@ Open a shared memory object.  Returns a file descriptor 
(integer).
 static int
 _posixshmem_shm_open_impl(PyObject *module, PyObject *path, int flags,
                           int mode)
-/*[clinic end generated code: output=8d110171a4fa20df input=0585935e1d3c8050]*/
+/*[clinic end generated code: output=8d110171a4fa20df input=e83b58fa802fac25]*/
 {
     int fd;
     int async_err = 0;

_______________________________________________
Python-checkins mailing list -- [email protected]
To unsubscribe send an email to [email protected]
https://mail.python.org/mailman3/lists/python-checkins.python.org/
Member address: [email protected]

Reply via email to