A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from http://mail.python.org/pipermail/python-bugs-list/2001-December/009132.html below:

[Python-bugs-list] [ python-Bugs-494007 ] Py_INCREF(Py_None) in documentation

[Python-bugs-list] [ python-Bugs-494007 ] Py_INCREF(Py_None) in documentation [Python-bugs-list] [ python-Bugs-494007 ] Py_INCREF(Py_None) in documentationnoreply@sourceforge.net noreply@sourceforge.net
Sun, 16 Dec 2001 15:19:35 -0800
Bugs item #494007, was opened at 2001-12-16 15:19
You can respond by visiting: 
http://sourceforge.net/tracker/?func=detail&atid=105470&aid=494007&group_id=5470

Category: Documentation
Group: None
Status: Open
Resolution: None
Priority: 5
Submitted By: Achim Gaedke (achimgaedke)
Assigned to: Fred L. Drake, Jr. (fdrake)
Summary: Py_INCREF(Py_None) in documentation

Initial Comment:
Since 5 hours I am debugging the pygsl (
http://pygsl.sourceforge.net ) module... The reason: I
forgot to increment the reference counter of Py_None
before returning it. Maybe it is a good idea to
underline this case. The Py_None object is a constant
pointer, maybe some other people do not think about it.

Here is a code example:

static PyObject* my_func(PyObject *self,
                           PyObject *args
                           )
{
  Py_INCREF(Py_None);
  return Py_None;
}

Is it possible, that this case was handled without
reference counter in version 2.0 and older?


----------------------------------------------------------------------

You can respond by visiting: 
http://sourceforge.net/tracker/?func=detail&atid=105470&aid=494007&group_id=5470



RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4