1
0
mirror of https://github.com/pgbackrest/pgbackrest.git synced 2025-07-05 00:28:52 +02:00

Move extern function comments to headers.

This has been the policy for some time but due to migration pressure only new functions and refactors have been following this rule. Now it seems sensible to make a clean sweep and move all the comments that have not been moved already (i.e. most of them).

Only obvious typos and gross inaccuracies in the comments have been fixed. For this most part this was a copy and paste operation.

Useless comments, e.g. "New object", were not copied. Even so, there are surely many deficient comments left.

Some rearranging was done where needed and functions were placed in the proper sections, e.g. "Constructors", "Functions", etc.

A few function prototypes were found that not longer had an implementation. These were removed, but there may be more.

The coding document has been updated to reflect this policy, which is not new but has never been documented.
This commit is contained in:
David Steele
2020-04-03 18:01:28 -04:00
parent 3fbde30c6f
commit 1aca2cc902
220 changed files with 1652 additions and 2131 deletions

View File

@ -40,9 +40,7 @@ OBJECT_DEFINE_FREE_RESOURCE_BEGIN(PG_CLIENT, LOG, logLevelTrace)
}
OBJECT_DEFINE_FREE_RESOURCE_END(LOG);
/***********************************************************************************************************************************
Create object
***********************************************************************************************************************************/
/**********************************************************************************************************************************/
PgClient *
pgClientNew(const String *host, const unsigned int port, const String *database, const String *user, const TimeMSec queryTimeout)
{
@ -119,9 +117,7 @@ pgClientEscape(const String *string)
FUNCTION_TEST_RETURN(result);
}
/***********************************************************************************************************************************
Open connection to PostgreSQL
***********************************************************************************************************************************/
/**********************************************************************************************************************************/
PgClient *
pgClientOpen(PgClient *this)
{
@ -167,9 +163,7 @@ pgClientOpen(PgClient *this)
FUNCTION_LOG_RETURN(PG_CLIENT, this);
}
/***********************************************************************************************************************************
Execute a query and return results
***********************************************************************************************************************************/
/**********************************************************************************************************************************/
VariantList *
pgClientQuery(PgClient *this, const String *query)
{
@ -340,9 +334,7 @@ pgClientQuery(PgClient *this, const String *query)
FUNCTION_LOG_RETURN(VARIANT_LIST, result);
}
/***********************************************************************************************************************************
Close connection to PostgreSQL
***********************************************************************************************************************************/
/**********************************************************************************************************************************/
void
pgClientClose(PgClient *this)
{
@ -362,9 +354,7 @@ pgClientClose(PgClient *this)
FUNCTION_LOG_RETURN_VOID();
}
/***********************************************************************************************************************************
Render as string for logging
***********************************************************************************************************************************/
/**********************************************************************************************************************************/
String *
pgClientToLog(const PgClient *this)
{