File: _portaudiomodule.c
Function: pa_get_device_count
Error: ob_refcnt of new ref from call to Py_BuildValue is 1 too high
1361 static PyObject *
1362 pa_get_device_count(PyObject *self, PyObject *args)
1363 {
1364   PaDeviceIndex count;
1365 
1366   if (!PyArg_ParseTuple(args, ""))
when PyArg_ParseTuple() succeeds
taking False path
1367     return NULL;
1368 
1369   count = Pa_GetDeviceCount();
1370   if (count < 0) {
when considering range: -0x80000000 <= value <= -1
taking True path
1371 
1372 #ifdef VERBOSE
1373     fprintf(stderr, "An error occured while using the portaudio stream\n");
1374     fprintf(stderr, "Error number: %d\n", count);
1375     fprintf(stderr, "Error message: %s\n", Pa_GetErrorText(count));
1376 #endif
1377 
1378     PyErr_SetObject(PyExc_IOError,
when Py_BuildValue() succeeds
calling PyErr_SetObject()
new ref from call to Py_BuildValue allocated at:     PyErr_SetObject(PyExc_IOError,
ob_refcnt is now refs: 1 + N where N >= 0
ob_refcnt is now refs: 1 + N where N >= 1
1379 		    Py_BuildValue("(s,i)",
1380 				  Pa_GetErrorText(count), count));
1381     return NULL;
1382   }
1383 
1384   return PyInt_FromLong(count);
1385 }
ob_refcnt of new ref from call to Py_BuildValue is 1 too high
was expecting final ob_refcnt to be N + 0 (for some unknown N)
but final ob_refcnt is N + 1