1. 03 May, 2002 2 kayıt (commit)
  2. 02 May, 2002 8 kayıt (commit)
  3. 01 May, 2002 2 kayıt (commit)
  4. 30 Nis, 2002 7 kayıt (commit)
    • Fred Drake's avatar
    • Anthony Baxter's avatar
      backport theller's patch: · 43eb1d3a
      Anthony Baxter yazdı
      Typo: whcar_t should be wchar_t.
      
      Bugfix candidate? Don't know how this is handled in the docs.
      
      Original patch(es):
      python/dist/src/Doc/api/concrete.tex:1.15
      43eb1d3a
    • Anthony Baxter's avatar
      backport tim_one's patch: · 91193370
      Anthony Baxter yazdı
      Repair widespread misuse of _PyString_Resize.  Since it's clear people
      don't understand how this function works, also beefed up the docs.  The
      most common usage error is of this form (often spread out across gotos):
      
      	if (_PyString_Resize(&s, n) < 0) {
      		Py_DECREF(s);
      		s = NULL;
      		goto outtahere;
      	}
      
      The error is that if _PyString_Resize runs out of memory, it automatically
      decrefs the input string object s (which also deallocates it, since its
      refcount must be 1 upon entry), and sets s to NULL.  So if the "if"
      branch ever triggers, it's an error to call Py_DECREF(s):  s is already
      NULL!  A correct way to write the above is the simpler (and intended)
      
      	if (_PyString_Resize(&s, n) < 0)
      		goto outtahere;
      
      Bugfix candidate.
      
      Original patch(es):
      python/dist/src/Python/bltinmodule.c:2.253
      91193370
    • Anthony Baxter's avatar
      backport tim_one's patch: · 3864a45c
      Anthony Baxter yazdı
      Repair widespread misuse of _PyString_Resize.  Since it's clear people
      don't understand how this function works, also beefed up the docs.  The
      most common usage error is of this form (often spread out across gotos):
      
      	if (_PyString_Resize(&s, n) < 0) {
      		Py_DECREF(s);
      		s = NULL;
      		goto outtahere;
      	}
      
      The error is that if _PyString_Resize runs out of memory, it automatically
      decrefs the input string object s (which also deallocates it, since its
      refcount must be 1 upon entry), and sets s to NULL.  So if the "if"
      branch ever triggers, it's an error to call Py_DECREF(s):  s is already
      NULL!  A correct way to write the above is the simpler (and intended)
      
      	if (_PyString_Resize(&s, n) < 0)
      		goto outtahere;
      
      Bugfix candidate.
      
      Original patch(es):
      python/dist/src/Objects/fileobject.c:2.161
      python/dist/src/Objects/stringobject.c:2.161
      python/dist/src/Objects/unicodeobject.c:2.147
      3864a45c
    • Anthony Baxter's avatar
      backport tim_one's patch: · 07fb92a8
      Anthony Baxter yazdı
      (some tweaking for different _PyObject_GC_Malloc() call in 2.2. checked,
      still returns the same thing on failure...)
      
      _PyObject_GC_New:  Could call PyObject_INIT with a NULL 1st argument.
      _PyObject_GC_NewVar:  Could call PyObject_INIT_VAR likewise.
      
      Bugfix candidate.
      
      Original patch(es):
      python/dist/src/Modules/gcmodule.c:2.40
      07fb92a8
    • Anthony Baxter's avatar
      backport tim_one's patch: · 608ee5a8
      Anthony Baxter yazdı
      Repair widespread misuse of _PyString_Resize.  Since it's clear people
      don't understand how this function works, also beefed up the docs.  The
      most common usage error is of this form (often spread out across gotos):
      
      	if (_PyString_Resize(&s, n) < 0) {
      		Py_DECREF(s);
      		s = NULL;
      		goto outtahere;
      	}
      
      The error is that if _PyString_Resize runs out of memory, it automatically
      decrefs the input string object s (which also deallocates it, since its
      refcount must be 1 upon entry), and sets s to NULL.  So if the "if"
      branch ever triggers, it's an error to call Py_DECREF(s):  s is already
      NULL!  A correct way to write the above is the simpler (and intended)
      
      	if (_PyString_Resize(&s, n) < 0)
      		goto outtahere;
      
      Bugfix candidate.
      
      Original patch(es):
      python/dist/src/Doc/api/concrete.tex:1.13
      608ee5a8
    • Fred Drake's avatar
      Added a missing "|" in the grammar productions used in the reference manual · 026ae2fd
      Fred Drake yazdı
      (reported by François Pinard).
      Added some missing "_" characters in the same cluster of productions.
      Added missing floor division operator in m_expr production, and mention
      floor division in the relevant portion of the text.
      026ae2fd
  5. 26 Nis, 2002 3 kayıt (commit)
  6. 24 Nis, 2002 2 kayıt (commit)
  7. 23 Nis, 2002 3 kayıt (commit)
  8. 22 Nis, 2002 4 kayıt (commit)
    • Walter Dörwald's avatar
      Backport checkin: · aa82bc08
      Walter Dörwald yazdı
      Apply patch diff.txt from SF feature request
      http://www.python.org/sf/444708
      
      This adds the optional argument for str.strip
      to unicode.strip too and makes it possible
      to call str.strip with a unicode argument
      and unicode.strip with a str argument.
      aa82bc08
    • Walter Dörwald's avatar
      Backport the following changes: · 1c097b71
      Walter Dörwald yazdı
      Misc/NEWS 1.387->1.388
      Lib/test/string_tests.py 1.10->1.11, 1.12->1.14,
      Lib/test/test_unicode.py 1.50->1.51, 1.53->1.54, 1.55->1.56
      Lib/test/test_string.py 1.15->1.16
      Lib/string.py 1.61->1.63
      Lib/test/test_userstring.py 1.5->1.6, 1.11, 1.12
      Objects/stringobject.c 2.156->2.159
      Objects/unicodeobject.c 2.137->2.139
      Doc/lib/libstdtypes.tec 1.87->1.88
      
      Add a method zfill to str, unicode and UserString
      and change Lib/string.py accordingly
      (see SF patch http://www.python.org/sf/536241)
      
      This also adds Guido's fix to test_userstring.py
      and the subinstance checks in test_string.py
      and test_unicode.py.
      1c097b71
    • Anthony Baxter's avatar
      backport mhammond's patch: · c3d8fa59
      Anthony Baxter yazdı
      Fix bug 544473 - "Queue module can deadlock".
      Use try/finally to ensure all Queue locks remain stable.
      Includes test case.  Bugfix candidate.
      
      (and branchpatch can now handle adding files :)
      c3d8fa59
    • cvs2svn's avatar
      This commit was manufactured by cvs2svn to create branch · d111f3b9
      cvs2svn yazdı
      'release22-maint'.
      d111f3b9
  9. 20 Nis, 2002 2 kayıt (commit)
  10. 19 Nis, 2002 5 kayıt (commit)
  11. 18 Nis, 2002 2 kayıt (commit)