]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
gh-106030: Miscellaneous fixes in Python/suggestions.c (GH-106031)
authorSerhiy Storchaka <storchaka@gmail.com>
Fri, 23 Jun 2023 16:53:27 +0000 (19:53 +0300)
committerGitHub <noreply@github.com>
Fri, 23 Jun 2023 16:53:27 +0000 (19:53 +0300)
commitc8c162ef5294cddb7ac75fe93ab918e5661c68ee
tree8181d2f2619c30996b4f24da7324d9e9c8dd15bc
parent9499b0f138cc53b9a2590350d0b545d2f69ee126
gh-106030: Miscellaneous fixes in Python/suggestions.c (GH-106031)

* PyDict_GetItem() and PyObject_HasAttr() suppress arbitrary errors and
  should not be used.
* PyUnicode_CompareWithASCIIString() only works if the second argument
  is ASCII string.
* Refleak in get_suggestions_for_name_error.
* Use of borrowed pointer after possible freeing (self).
* Add some missing error checks.
Python/suggestions.c