1. 16 Dec, 2017 4 commits
    • Benjamin Peterson's avatar
      fix up signedness in PyImport_ExtendInittab (#4831) · 0c644fcd
      Benjamin Peterson authored
      As a result of 92a3c6f4, the compiler complains:
      
      Python/import.c:2311:21: warning: comparison of integers of different signs: 'long' and 'unsigned long' [-Wsign-compare]
          if ((i + n + 1) <= PY_SSIZE_T_MAX / sizeof(struct _inittab)) {
               ~~~~~~~~~  ^  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      
      This overflow is extremely unlikely to happen, but let's avoid undefined
      behavior anyway.
      0c644fcd
    • Victor Stinner's avatar
      bpo-29240, bpo-32030: Py_Main() re-reads config if encoding changes (#4899) · 9454060e
      Victor Stinner authored
      bpo-29240, bpo-32030: If the encoding change (C locale coerced or
      UTF-8 Mode changed), Py_Main() now reads again the configuration with
      the new encoding.
      
      Changes:
      
      * Add _Py_UnixMain() called by main().
      * Rename pymain_free_pymain() to pymain_clear_pymain(), it can now be
        called multipled times.
      * Rename pymain_parse_cmdline_envvars() to pymain_read_conf().
      * Py_Main() now clears orig_argc and orig_argv at exit.
      * Remove argv_copy2, Py_Main() doesn't modify argv anymore. There is
        no need anymore to get two copies of the wchar_t** argv.
      * _PyCoreConfig: add coerce_c_locale and coerce_c_locale_warn.
      * Py_UTF8Mode is now initialized to -1.
      * Locale coercion (PEP 538) now respects -I and -E options.
      9454060e
    • Yury Selivanov's avatar
      e796b2fe
    • Brett Cannon's avatar
  2. 15 Dec, 2017 15 commits
  3. 14 Dec, 2017 14 commits
  4. 13 Dec, 2017 7 commits