mirror of
https://github.com/postgres/postgres.git
synced 2025-06-13 07:41:39 +03:00
pgindent run for release 9.3
This is the first run of the Perl-based pgindent script. Also update pgindent instructions.
This commit is contained in:
@ -41,7 +41,7 @@ timestamptz_to_time_t(TimestampTz t)
|
||||
|
||||
/*
|
||||
* Stopgap implementation of timestamptz_to_str that doesn't depend on backend
|
||||
* infrastructure. This will work for timestamps that are within the range
|
||||
* infrastructure. This will work for timestamps that are within the range
|
||||
* of the platform time_t type. (pg_time_t is compatible except for possibly
|
||||
* being wider.)
|
||||
*
|
||||
@ -77,7 +77,7 @@ timestamptz_to_str(TimestampTz dt)
|
||||
* be linked/called.
|
||||
*/
|
||||
void
|
||||
appendStringInfo(StringInfo str, const char *fmt, ...)
|
||||
appendStringInfo(StringInfo str, const char *fmt,...)
|
||||
{
|
||||
va_list args;
|
||||
|
||||
|
@ -73,7 +73,7 @@ fatal_error(const char *fmt,...)
|
||||
static void
|
||||
print_rmgr_list(void)
|
||||
{
|
||||
int i;
|
||||
int i;
|
||||
|
||||
for (i = 0; i < RM_MAX_ID + 1; i++)
|
||||
{
|
||||
@ -88,7 +88,8 @@ print_rmgr_list(void)
|
||||
static bool
|
||||
verify_directory(const char *directory)
|
||||
{
|
||||
DIR *dir = opendir(directory);
|
||||
DIR *dir = opendir(directory);
|
||||
|
||||
if (dir == NULL)
|
||||
return false;
|
||||
closedir(dir);
|
||||
@ -113,7 +114,7 @@ split_path(const char *path, char **dir, char **fname)
|
||||
if (sep != NULL)
|
||||
{
|
||||
*dir = pg_strdup(path);
|
||||
(*dir)[(sep - path) + 1] = '\0'; /* no strndup */
|
||||
(*dir)[(sep - path) + 1] = '\0'; /* no strndup */
|
||||
*fname = pg_strdup(sep + 1);
|
||||
}
|
||||
/* local directory */
|
||||
@ -596,7 +597,7 @@ main(int argc, char **argv)
|
||||
else if (!XLByteInSeg(private.startptr, segno))
|
||||
{
|
||||
fprintf(stderr,
|
||||
"%s: start log position %X/%X is not inside file \"%s\"\n",
|
||||
"%s: start log position %X/%X is not inside file \"%s\"\n",
|
||||
progname,
|
||||
(uint32) (private.startptr >> 32),
|
||||
(uint32) private.startptr,
|
||||
@ -672,9 +673,9 @@ main(int argc, char **argv)
|
||||
(uint32) private.startptr);
|
||||
|
||||
/*
|
||||
* Display a message that we're skipping data if `from` wasn't a pointer to
|
||||
* the start of a record and also wasn't a pointer to the beginning of a
|
||||
* segment (e.g. we were used in file mode).
|
||||
* Display a message that we're skipping data if `from` wasn't a pointer
|
||||
* to the start of a record and also wasn't a pointer to the beginning of
|
||||
* a segment (e.g. we were used in file mode).
|
||||
*/
|
||||
if (first_record != private.startptr && (private.startptr % XLogSegSize) != 0)
|
||||
printf("first record is after %X/%X, at %X/%X, skipping over %u bytes\n",
|
||||
|
@ -33,4 +33,3 @@
|
||||
const RmgrDescData RmgrDescTable[RM_MAX_ID + 1] = {
|
||||
#include "access/rmgrlist.h"
|
||||
};
|
||||
|
||||
|
@ -13,9 +13,9 @@
|
||||
typedef struct RmgrDescData
|
||||
{
|
||||
const char *rm_name;
|
||||
void (*rm_desc) (StringInfo buf, uint8 xl_info, char *rec);
|
||||
void (*rm_desc) (StringInfo buf, uint8 xl_info, char *rec);
|
||||
} RmgrDescData;
|
||||
|
||||
extern const RmgrDescData RmgrDescTable[];
|
||||
|
||||
#endif /* RMGRDESC_H */
|
||||
#endif /* RMGRDESC_H */
|
||||
|
Reference in New Issue
Block a user