PostgreSQL Source Code
git master
|
#include "postgres_fe.h"
#include "common/logging.h"
#include "fe_utils/recovery_gen.h"
#include "fe_utils/string_utils.h"
Go to the source code of this file.
Functions | |
static char * | escape_quotes (const char *src) |
PQExpBuffer | GenerateRecoveryConfig (PGconn *pgconn, const char *replication_slot, char *dbname) |
void | WriteRecoveryConfig (PGconn *pgconn, const char *target_dir, PQExpBuffer contents) |
|
static |
Definition at line 163 of file recovery_gen.c.
References escape_single_quotes_ascii(), and pg_fatal.
Referenced by GenerateRecoveryConfig().
PQExpBuffer GenerateRecoveryConfig | ( | PGconn * | pgconn, |
const char * | replication_slot, | ||
char * | dbname | ||
) |
Definition at line 27 of file recovery_gen.c.
References appendConnStrVal(), appendPQExpBuffer(), appendPQExpBufferChar(), appendPQExpBufferStr(), Assert, createPQExpBuffer(), PQExpBufferData::data, dbname, escape_quotes(), free, initPQExpBuffer(), _PQconninfoOption::keyword, PQExpBufferData::len, MINIMUM_VERSION_FOR_RECOVERY_GUC, pg_fatal, PQconninfo(), PQconninfoFree(), PQExpBufferBroken, PQExpBufferDataBroken, PQserverVersion(), replication_slot, and termPQExpBuffer().
Referenced by BaseBackup(), main(), and setup_recovery().
void WriteRecoveryConfig | ( | PGconn * | pgconn, |
const char * | target_dir, | ||
PQExpBuffer | contents | ||
) |
Definition at line 124 of file recovery_gen.c.
References Assert, PQExpBufferData::data, filename, PQExpBufferData::len, MAXPGPATH, MINIMUM_VERSION_FOR_RECOVERY_GUC, pg_fatal, PQserverVersion(), and snprintf.
Referenced by main(), and setup_recovery().