Changeset c6909f in git


Ignore:
Timestamp:
Jul 2, 2012, 9:41:28 PM (11 years ago)
Author:
Alexander Dreyer <alexander.dreyer@…>
Branches:
(u'jengelh-datetime', 'ceac47cbc86fe4a15902392bdbb9bd2ae0ea02c6')(u'spielwiese', 'c987db42cd2ec943b97ac5746c99892ceddf909c')
Children:
ee7fda9661a001786754f195184c34514b936d56
Parents:
3877fe9f0c88727f965577a93a4ea1c2464e3978
git-author:
Alexander Dreyer <alexander.dreyer@itwm.fraunhofer.de>2012-07-02 21:41:28+02:00
git-committer:
Alexander Dreyer <alexander.dreyer@itwm.fraunhofer.de>2012-08-01 23:38:16+02:00
Message:
fix: need to handle reference count of Py_None, too
File:
1 edited

Legend:

Unmodified
Added
Removed
  • Singular/pyobject.cc

    r3877fe rc6909f  
    271271  BOOLEAN none_to(leftv result) const
    272272  {
     273    Py_XINCREF(m_ptr);
    273274    result->data = NULL;
    274275    result->rtyp = NONE;
     
    445446  PyRun_SimpleString(reinterpret_cast<const char*>(arg->Data()));
    446447  sync_contexts();
     448
     449  Py_XINCREF(Py_None);
    447450  return PythonCastStatic<>(Py_None).assign_to(result);
    448451}
     
    477480  sync_contexts();
    478481
     482  Py_XINCREF(Py_None);
    479483  return PythonCastStatic<>(Py_None).assign_to(result);
    480484}
     
    483487void* pyobject_Init(blackbox*)
    484488{
     489  Py_XINCREF(Py_None);
    485490  return Py_None;
    486491}
Note: See TracChangeset for help on using the changeset viewer.