Commit 0994cfc0 authored by Alvaro Herrera's avatar Alvaro Herrera

Don't uselessly escape a string that doesn't need escaping

Per gripe from Ian Barwick
Co-authored-by: default avatarIan Barwick <ian@2ndquadrant.com>
Discussion: https://postgr.es/m/CABvVfJWNnNKb8cHsTLhkTsvL1+G6BVcV+57+w1JZ61p8YGPdWQ@mail.gmail.com
parent 8ab66081
......@@ -1716,9 +1716,9 @@ GenerateRecoveryConf(PGconn *conn)
if (replication_slot)
{
escaped = escape_quotes(replication_slot);
appendPQExpBuffer(recoveryconfcontents, "primary_slot_name = '%s'\n", replication_slot);
free(escaped);
/* unescaped: ReplicationSlotValidateName allows [a-z0-9_] only */
appendPQExpBuffer(recoveryconfcontents, "primary_slot_name = '%s'\n",
replication_slot);
}
if (PQExpBufferBroken(recoveryconfcontents) ||
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment