]> granicus.if.org Git - postgresql/commitdiff
Fix operator naming in pg_trgm GUC option descriptions
authorAlexander Korotkov <akorotkov@postgresql.org>
Mon, 10 Jun 2019 17:14:19 +0000 (20:14 +0300)
committerAlexander Korotkov <akorotkov@postgresql.org>
Mon, 10 Jun 2019 17:27:48 +0000 (20:27 +0300)
Descriptions of pg_trgm GUC options have % replaced with %% like it was
a printf-like format.  But that's not needed since they are just plain strings.
This commit fixed that.  Backpatch to last supported version since this error
present from the beginning.

Reported-by: Masahiko Sawada
Discussion: https://postgr.es/m/CAD21AoAgPKODUsu9gqUFiNqEOAqedStxJ-a0sapsJXWWAVp%3Dxg%40mail.gmail.com
Backpatch-through: 9.4

contrib/pg_trgm/trgm_op.c

index 32adecc9b82d1619b13f9922076427bd86d2dbd8..4ab9e0bcced7cbd1736f96d59247226a018cd5dc 100644 (file)
@@ -48,7 +48,7 @@ _PG_init(void)
 {
        /* Define custom GUC variables. */
        DefineCustomRealVariable("pg_trgm.similarity_threshold",
-                                                        "Sets the threshold used by the %% operator.",
+                                                        "Sets the threshold used by the % operator.",
                                                         "Valid range is 0.0 .. 1.0.",
                                                         &similarity_threshold,
                                                         0.3,
@@ -60,7 +60,7 @@ _PG_init(void)
                                                         NULL,
                                                         NULL);
        DefineCustomRealVariable("pg_trgm.word_similarity_threshold",
-                                                        "Sets the threshold used by the <%% operator.",
+                                                        "Sets the threshold used by the <% operator.",
                                                         "Valid range is 0.0 .. 1.0.",
                                                         &word_similarity_threshold,
                                                         0.6,