diff options
Diffstat (limited to 'src/backend/utils/cache/typcache.c')
-rw-r--r-- | src/backend/utils/cache/typcache.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/backend/utils/cache/typcache.c b/src/backend/utils/cache/typcache.c index 70e5c51297d..d140ef66552 100644 --- a/src/backend/utils/cache/typcache.c +++ b/src/backend/utils/cache/typcache.c @@ -1820,8 +1820,11 @@ lookup_rowtype_tupdesc_internal(Oid type_id, int32 typmod, bool noError) * for example from record_in().) * * Note: on success, we increment the refcount of the returned TupleDesc, - * and log the reference in CurrentResourceOwner. Caller should call - * ReleaseTupleDesc or DecrTupleDescRefCount when done using the tupdesc. + * and log the reference in CurrentResourceOwner. Caller must call + * ReleaseTupleDesc when done using the tupdesc. (There are some + * cases in which the returned tupdesc is not refcounted, in which + * case PinTupleDesc/ReleaseTupleDesc are no-ops; but in these cases + * the tupdesc is guaranteed to live till process exit.) */ TupleDesc lookup_rowtype_tupdesc(Oid type_id, int32 typmod) |