[Python-checkins] GH-95896: posixmodule.c: fix osdefs.h inclusion to not depend on compiler (#95897)
kumaraditya303
webhook-mailer at python.org
Sat Nov 26 04:32:19 EST 2022
https://github.com/python/cpython/commit/ec2b76aa8b7c6313293ff9c6814e8bc31e08fcaf
commit: ec2b76aa8b7c6313293ff9c6814e8bc31e08fcaf
branch: main
author: TheShermanTanker <32636402+TheShermanTanker at users.noreply.github.com>
committer: kumaraditya303 <59607654+kumaraditya303 at users.noreply.github.com>
date: 2022-11-26T15:01:42+05:30
summary:
GH-95896: posixmodule.c: fix osdefs.h inclusion to not depend on compiler (#95897)
Co-authored-by: Steve Dower <steve.dower at python.org>
files:
M Modules/posixmodule.c
diff --git a/Modules/posixmodule.c b/Modules/posixmodule.c
index 8185517b06b5..95ecf1c7c4b2 100644
--- a/Modules/posixmodule.c
+++ b/Modules/posixmodule.c
@@ -16,6 +16,9 @@
#ifdef MS_WINDOWS
# include <windows.h>
# include <pathcch.h>
+# include <lmcons.h> // UNLEN
+# include "osdefs.h" // SEP
+# define HAVE_SYMLINK
#endif
#ifdef __VXWORKS__
@@ -426,18 +429,7 @@ extern char *ctermid_r(char *);
# ifdef HAVE_PROCESS_H
# include <process.h>
# endif
-# ifndef IO_REPARSE_TAG_SYMLINK
-# define IO_REPARSE_TAG_SYMLINK (0xA000000CL)
-# endif
-# ifndef IO_REPARSE_TAG_MOUNT_POINT
-# define IO_REPARSE_TAG_MOUNT_POINT (0xA0000003L)
-# endif
-# include "osdefs.h" // SEP
# include <malloc.h>
-# include <windows.h>
-# include <shellapi.h> // ShellExecute()
-# include <lmcons.h> // UNLEN
-# define HAVE_SYMLINK
#endif /* _MSC_VER */
#ifndef MAXPATHLEN
More information about the Python-checkins
mailing list