Fix comment in libpqrcv_check_conninfo().
authorFujii Masao <[email protected]>
Tue, 9 Jul 2024 12:03:56 +0000 (21:03 +0900)
committerFujii Masao <[email protected]>
Tue, 9 Jul 2024 12:30:18 +0000 (21:30 +0900)
Previously, the comment incorrectly stated that libpqrcv_check_conninfo()
returns true or false based on the connection string check.
However, this function actually has a void return type and
raises an error if the check fails.

Author: Rintaro Ikeda
Reviewed-by: Jelte Fennema-Nio, Fujii Masao
Discussion: https://postgr.es/m/6a1ca81b27fec4da0ccdfaaaec787982@oss.nttdata.com

src/backend/replication/libpqwalreceiver/libpqwalreceiver.c

index 02f12f2921939b2dbc9d9d280fb4d4e74b885596..6c42c209d2977c49c40890fda3a11ec8954d25b6 100644 (file)
@@ -305,12 +305,12 @@ bad_connection:
 }
 
 /*
- * Validate connection info string, and determine whether it might cause
- * local filesystem access to be attempted.
+ * Validate connection info string.
  *
  * If the connection string can't be parsed, this function will raise
- * an error and will not return. If it can, it will return true if this
- * connection string specifies a password and false otherwise.
+ * an error. If must_use_password is true, the function raises an error
+ * if no password is provided in the connection string. In any other case
+ * it successfully completes.
  */
 static void
 libpqrcv_check_conninfo(const char *conninfo, bool must_use_password)