[Groonga-commit] pgroonga/pgroonga at 6cb47fc [master] Use PG_GETARG_HEAPTUPLEHEADER()

Back to archive index

Kouhei Sutou null+****@clear*****
Sat Feb 14 18:59:10 JST 2015


Kouhei Sutou	2015-02-14 18:59:10 +0900 (Sat, 14 Feb 2015)

  New Revision: 6cb47fca05b81d6cc6a1c0a0a0077cf67b7f7c1b
  https://github.com/pgroonga/pgroonga/commit/6cb47fca05b81d6cc6a1c0a0a0077cf67b7f7c1b

  Message:
    Use PG_GETARG_HEAPTUPLEHEADER()

  Modified files:
    pgroonga.c

  Modified: pgroonga.c (+1 -3)
===================================================================
--- pgroonga.c    2015-02-14 17:00:48 +0900 (6676f4a)
+++ pgroonga.c    2015-02-14 18:59:10 +0900 (c13c4ce)
@@ -693,14 +693,12 @@ PGrnCollectScore(Oid tableID, ItemPointer ctid)
 Datum
 pgroonga_score(PG_FUNCTION_ARGS)
 {
-	Datum row = PG_GETARG_DATUM(0);
-	HeapTupleHeader header;
+	HeapTupleHeader header = PG_GETARG_HEAPTUPLEHEADER(0);
 	Oid	type;
 	int32 recordType;
 	TupleDesc desc;
 	double score = 0.0;
 
-	header = DatumGetHeapTupleHeader(row);
 	type = HeapTupleHeaderGetTypeId(header);
 	recordType = HeapTupleHeaderGetTypMod(header);
 	desc = lookup_rowtype_tupdesc(type, recordType);
-------------- next part --------------
HTML����������������������������...
Download 



More information about the Groonga-commit mailing list
Back to archive index