MCPcopy Create free account
hub / github.com/apache/cloudberry / geterrposition

Function geterrposition

src/backend/utils/error/elog.c:1652–1661  ·  view source on GitHub ↗

* geterrposition --- return the currently set error position (0 if none) * * This is only intended for use in error callback subroutines, since there * is no other place outside elog.c where the concept is meaningful. */

Source from the content-addressed store, hash-verified

1650 * is no other place outside elog.c where the concept is meaningful.
1651 */
1652int
1653geterrposition(void)
1654{
1655 ErrorData *edata = &errordata[errordata_stack_depth];
1656
1657 /* we don't bother incrementing recursion_depth */
1658 CHECK_STACK_DEPTH();
1659
1660 return edata->cursorpos;
1661}
1662
1663/*
1664 * getinternalerrposition --- same for internal error position

Callers 6

import_error_callbackFunction · 0.50
sql_exec_error_callbackFunction · 0.50
_SPI_error_callbackFunction · 0.50

Calls

no outgoing calls

Tested by

no test coverage detected