Index: Python/Python-ast.c =================================================================== --- Python/Python-ast.c (revision 61001) +++ Python/Python-ast.c (working copy) @@ -2,7 +2,7 @@ /* - __version__ 53731. + __version__ 60978. This module must be committed separately after each AST grammar change; The __version__ number is set to the revision number of the commit @@ -2958,7 +2958,7 @@ if (PyDict_SetItemString(d, "AST", (PyObject*)AST_type) < 0) return; if (PyModule_AddIntConstant(m, "PyCF_ONLY_AST", PyCF_ONLY_AST) < 0) return; - if (PyModule_AddStringConstant(m, "__version__", "53731") < 0) + if (PyModule_AddStringConstant(m, "__version__", "60978") < 0) return; if (PyDict_SetItemString(d, "mod", (PyObject*)mod_type) < 0) return; if (PyDict_SetItemString(d, "Module", (PyObject*)Module_type) < 0) Index: setup.py =================================================================== --- setup.py (revision 61001) +++ setup.py (working copy) @@ -823,18 +823,18 @@ # correct and most trouble free, but may cause problems in # some unusual system configurations (e.g. the directory # is on an NFS server that goes away). - exts.append(Extension('_bsddb', ['_bsddb.c'], - depends = ['bsddb.h'], - library_dirs=dblib_dir, - runtime_library_dirs=dblib_dir, - include_dirs=db_incs, - libraries=dblibs)) + #exts.append(Extension('_bsddb', ['_bsddb.c'], + # depends = ['bsddb.h'], + # library_dirs=dblib_dir, + # runtime_library_dirs=dblib_dir, + # include_dirs=db_incs, + # libraries=dblibs)) else: if db_setup_debug: print "db: no appropriate library found" db_incs = None dblibs = [] dblib_dir = None - missing.append('_bsddb') + #missing.append('_bsddb') # The sqlite interface sqlite_setup_debug = False # verbose debug prints from this script? @@ -957,9 +957,11 @@ else: exts.append(Extension('bsddb185', ['bsddbmodule.c'])) else: - missing.append('bsddb185') + #missing.append('bsddb185') + pass else: - missing.append('bsddb185') + #missing.append('bsddb185') + pass # The standard Unix dbm module: if platform not in ['cygwin']: @@ -986,14 +988,16 @@ ('DB_DBM_HSEARCH',None)], libraries=dblibs)) else: - missing.append('dbm') + #missing.append('dbm') + pass # Anthony Baxter's gdbm module. GNU dbm(3) will require -lgdbm: if (self.compiler.find_library_file(lib_dirs, 'gdbm')): exts.append( Extension('gdbm', ['gdbmmodule.c'], libraries = ['gdbm'] ) ) else: - missing.append('gdbm') + #missing.append('gdbm') + pass # Unix-only modules if platform not in ['mac', 'win32']: @@ -1191,7 +1195,8 @@ # SunOS specific modules exts.append( Extension('sunaudiodev', ['sunaudiodev.c']) ) else: - missing.append('sunaudiodev') + #missing.append('sunaudiodev') + pass if platform == 'darwin' and ("--disable-toolbox-glue" not in sysconfig.get_config_var("CONFIG_ARGS")): Index: Objects/fileobject.c =================================================================== --- Objects/fileobject.c (revision 61001) +++ Objects/fileobject.c (working copy) @@ -892,6 +892,11 @@ } if (bytesrequested < 0) { buffersize = new_buffersize(f, buffersize); + if (buffersize > PY_SSIZE_T_MAX) { + PyErr_SetString(PyExc_OverflowError, + "unbounded read consumed more bytes than a Python string can hold"); + return NULL; + } if (_PyString_Resize(&v, buffersize) < 0) return NULL; } else {