From 2514d08d0dc6d28a59bd884a751b734c70e2c0c0 Mon Sep 17 00:00:00 2001 From: Cynthia Shang Date: Mon, 10 Dec 2018 18:15:06 -0500 Subject: [PATCH] Remove #define statements in the InfoPg module to conform with newly-adopted coding standards. Contributed by Cynthia Shang. --- doc/xml/release.xml | 2 +- src/info/infoPg.c | 20 ++++++-------------- 2 files changed, 7 insertions(+), 15 deletions(-) diff --git a/doc/xml/release.xml b/doc/xml/release.xml index 4f0ca0589..ddda88431 100644 --- a/doc/xml/release.xml +++ b/doc/xml/release.xml @@ -112,7 +112,7 @@ -

Rename constants in Info module for consistency.

+

Info module improvements. Rename constants in Info module for consistency. Remove #define statements in the InfoPg module to conform with newly-adopted coding standards.

diff --git a/src/info/infoPg.c b/src/info/infoPg.c index 3d81141f1..d9e7e5fb1 100644 --- a/src/info/infoPg.c +++ b/src/info/infoPg.c @@ -23,21 +23,13 @@ PostgreSQL Info Handler /*********************************************************************************************************************************** Internal constants ***********************************************************************************************************************************/ -#define INFO_SECTION_DB "db" -#define INFO_SECTION_DB_HISTORY INFO_SECTION_DB ":history" - STRING_STATIC(INFO_SECTION_DB_HISTORY_STR, INFO_SECTION_DB_HISTORY); -#define INFO_SECTION_DB_MANIFEST "backup:" INFO_SECTION_DB +STRING_STATIC(INFO_SECTION_DB_HISTORY_STR, "db:history"); -#define INFO_KEY_DB_ID "db-id" - STRING_STATIC(INFO_KEY_DB_ID_STR, INFO_KEY_DB_ID); -#define INFO_KEY_DB_CATALOG_VERSION "db-catalog-version" - STRING_STATIC(INFO_KEY_DB_CATALOG_VERSION_STR, INFO_KEY_DB_CATALOG_VERSION); -#define INFO_KEY_DB_CONTROL_VERSION "db-control-version" - STRING_STATIC(INFO_KEY_DB_CONTROL_VERSION_STR, INFO_KEY_DB_CONTROL_VERSION); -#define INFO_KEY_DB_SYSTEM_ID "db-system-id" - STRING_STATIC(INFO_KEY_DB_SYSTEM_ID_STR, INFO_KEY_DB_SYSTEM_ID); -#define INFO_KEY_DB_VERSION "db-version" - STRING_STATIC(INFO_KEY_DB_VERSION_STR, INFO_KEY_DB_VERSION); +STRING_STATIC(INFO_KEY_DB_ID_STR, "db-id"); +STRING_STATIC(INFO_KEY_DB_CATALOG_VERSION_STR, "db-catalog-version"); +STRING_STATIC(INFO_KEY_DB_CONTROL_VERSION_STR, "db-control-version"); +STRING_STATIC(INFO_KEY_DB_SYSTEM_ID_STR, "db-system-id"); +STRING_STATIC(INFO_KEY_DB_VERSION_STR, "db-version"); /*********************************************************************************************************************************** Object type