@@ -321,11 +321,13 @@ timetravel(PG_FUNCTION_ARGS)
321
321
if (!(tupdesc -> attrs [i - 1 ]-> attisdropped )) /* skip dropped columns */
322
322
snprintf (sql + strlen (sql ), sizeof (sql ) - strlen (sql ), "$%d%s" ,
323
323
i , (i < natts ) ? ", " : ")" );
324
- // snprintf(sql + strlen(sql), sizeof(sql) - strlen(sql), "$%d /* %d */ %s",
325
- // i, ctypes[i-1], (i < natts) ? ", " : ")" );
324
+ #if 0
325
+ snprintf (sql + strlen (sql ), sizeof (sql ) - strlen (sql ), "$%d /* %d */ %s" ,
326
+ i , ctypes [i - 1 ], (i < natts ) ? ", " : ")" );
327
+ #endif
326
328
}
327
329
328
- // elog(NOTICE , "timetravel (%s) update: sql: %s", relname, sql);
330
+ elog (DEBUG4 , "timetravel (%s) update: sql: %s" , relname , sql );
329
331
330
332
/* Prepare plan for query */
331
333
pplan = SPI_prepare (sql , natts , ctypes );
@@ -395,10 +397,9 @@ timetravel(PG_FUNCTION_ARGS)
395
397
* SPI_copytuple allocates tmptuple in upper executor context -
396
398
* have to free allocation using SPI_pfree
397
399
*/
398
- // SPI_pfree(tmptuple);
400
+ /* SPI_pfree(tmptuple); */
399
401
}
400
- else
401
- /* DELETE */
402
+ else /* DELETE case */
402
403
rettuple = trigtuple ;
403
404
404
405
SPI_finish (); /* don't forget say Bye to SPI mgr */
0 commit comments