mirror of
https://github.com/postgres/postgres.git
synced 2026-04-15 22:10:45 -04:00
Use PyObject_New instead of PyObject_NEW
The latter is undocumented and the speed gain is negligible. Jan Urbański
This commit is contained in:
parent
41282111e6
commit
d9a95c0adb
1 changed files with 2 additions and 2 deletions
|
|
@ -2671,7 +2671,7 @@ PLy_plan_new(void)
|
|||
{
|
||||
PLyPlanObject *ob;
|
||||
|
||||
if ((ob = PyObject_NEW(PLyPlanObject, &PLy_PlanType)) == NULL)
|
||||
if ((ob = PyObject_New(PLyPlanObject, &PLy_PlanType)) == NULL)
|
||||
return NULL;
|
||||
|
||||
ob->plan = NULL;
|
||||
|
|
@ -2727,7 +2727,7 @@ PLy_result_new(void)
|
|||
{
|
||||
PLyResultObject *ob;
|
||||
|
||||
if ((ob = PyObject_NEW(PLyResultObject, &PLy_ResultType)) == NULL)
|
||||
if ((ob = PyObject_New(PLyResultObject, &PLy_ResultType)) == NULL)
|
||||
return NULL;
|
||||
|
||||
/* ob->tuples = NULL; */
|
||||
|
|
|
|||
Loading…
Reference in a new issue