summaryrefslogtreecommitdiff
path: root/doc/src
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2020-03-28 17:09:51 -0400
committerTom Lane <tgl@sss.pgh.pa.us>2020-03-28 17:09:51 -0400
commit2618ac6c6535171f4993a38e3410955e1c2a2073 (patch)
tree00b4c412286c96f772c8aa761dbf7e49f0a1ae87 /doc/src
parenta0e2a178c6409db195e8e902e4ac279ad60777cb (diff)
Protect against overflow of ltree.numlevel and lquery.numlevel.
These uint16 fields could be overflowed by excessively long input, producing strange results. Complain for invalid input. Likewise check for out-of-range values of the repeat counts in lquery. (We don't try too hard on that one, notably not bothering to detect if atoi's result has overflowed.) Also detect length overflow in ltree_concat. In passing, be more consistent about whether "syntax error" messages include the type name. Also, clarify the documentation about what the size limit is. This has been broken for a long time, so back-patch to all supported branches. Nikita Glukhov, reviewed by Benjie Gillam and Tomas Vondra Discussion: https://postgr.es/m/CAP_rww=waX2Oo6q+MbMSiZ9ktdj6eaJj0cQzNu=Ry2cCDij5fw@mail.gmail.com
Diffstat (limited to 'doc/src')
-rw-r--r--doc/src/sgml/ltree.sgml3
1 files changed, 1 insertions, 2 deletions
diff --git a/doc/src/sgml/ltree.sgml b/doc/src/sgml/ltree.sgml
index 77599adeafd..97dc8aa2d06 100644
--- a/doc/src/sgml/ltree.sgml
+++ b/doc/src/sgml/ltree.sgml
@@ -31,8 +31,7 @@
A <firstterm>label path</firstterm> is a sequence of zero or more
labels separated by dots, for example <literal>L1.L2.L3</>, representing
a path from the root of a hierarchical tree to a particular node. The
- length of a label path must be less than 65kB, but keeping it under 2kB is
- preferable.
+ length of a label path cannot exceed 65535 labels.
</para>
<para>