Skip to content

Commit b49154b

Browse files
committed
Simplify some comments in xml.c
Author: Justin Pryzby Discussion: https://postgr.es/m/X/[email protected]
1 parent a271a1b commit b49154b

File tree

1 file changed

+3
-9
lines changed
  • src/backend/utils/adt

1 file changed

+3
-9
lines changed

src/backend/utils/adt/xml.c

+3-9
Original file line numberDiff line numberDiff line change
@@ -4534,13 +4534,7 @@ XmlTableFetchRow(TableFuncScanState *state)
45344534

45354535
xtCxt = GetXmlTableBuilderPrivateData(state, "XmlTableFetchRow");
45364536

4537-
/*
4538-
* XmlTable returns table - set of composite values. The error context, is
4539-
* used for producement more values, between two calls, there can be
4540-
* created and used another libxml2 error context. It is libxml2 global
4541-
* value, so it should be refreshed any time before any libxml2 usage,
4542-
* that is finished by returning some value.
4543-
*/
4537+
/* Propagate our own error context to libxml2 */
45444538
xmlSetStructuredErrorFunc((void *) xtCxt->xmlerrcxt, xml_errorHandler);
45454539

45464540
if (xtCxt->xpathobj == NULL)
@@ -4594,7 +4588,7 @@ XmlTableGetValue(TableFuncScanState *state, int colnum,
45944588
xtCxt->xpathobj->type == XPATH_NODESET &&
45954589
xtCxt->xpathobj->nodesetval != NULL);
45964590

4597-
/* Propagate context related error context to libxml2 */
4591+
/* Propagate our own error context to libxml2 */
45984592
xmlSetStructuredErrorFunc((void *) xtCxt->xmlerrcxt, xml_errorHandler);
45994593

46004594
*isnull = false;
@@ -4737,7 +4731,7 @@ XmlTableDestroyOpaque(TableFuncScanState *state)
47374731

47384732
xtCxt = GetXmlTableBuilderPrivateData(state, "XmlTableDestroyOpaque");
47394733

4740-
/* Propagate context related error context to libxml2 */
4734+
/* Propagate our own error context to libxml2 */
47414735
xmlSetStructuredErrorFunc((void *) xtCxt->xmlerrcxt, xml_errorHandler);
47424736

47434737
if (xtCxt->xpathscomp != NULL)

0 commit comments

Comments
 (0)