summaryrefslogtreecommitdiff
path: root/Python/getopt.c
diff options
context:
space:
mode:
authorGeorg Brandl <georg@python.org>2012-02-20 21:31:46 +0100
committerGeorg Brandl <georg@python.org>2012-02-20 21:31:46 +0100
commitc046a714e1f2152c7f45bc90d6f3829c34e7029f (patch)
tree4ad97aaf7ffcf9e49750a59179ef736b8e62e6e1 /Python/getopt.c
parent5af1ccb2a86c32b4a7ed302bd75dd824606fc222 (diff)
parent9edd5e108cf2736595d6bb117e1a2a45b4403e85 (diff)
downloadcpython-c046a714e1f2152c7f45bc90d6f3829c34e7029f.tar.gz
Merge from 3.1: Issue #13703: add a way to randomize the hash values of basic types (str, bytes, datetime)
in order to make algorithmic complexity attacks on (e.g.) web apps much more complicated. The environment variable PYTHONHASHSEED and the new command line flag -R control this behavior.
Diffstat (limited to 'Python/getopt.c')
-rw-r--r--Python/getopt.c6
1 files changed, 0 insertions, 6 deletions
diff --git a/Python/getopt.c b/Python/getopt.c
index 5147320af2..064a1874ea 100644
--- a/Python/getopt.c
+++ b/Python/getopt.c
@@ -89,12 +89,6 @@ int _PyOS_GetOpt(int argc, wchar_t **argv, wchar_t *optstring)
return '_';
}
- if (option == 'X') {
- fprintf(stderr,
- "-X is reserved for implementation-specific arguments\n");
- return '_';
- }
-
if ((ptr = wcschr(optstring, option)) == NULL) {
if (_PyOS_opterr)
fprintf(stderr, "Unknown option: -%c\n", (char)option);