Skip to content

Commit 788af6f

Browse files
committed
Move atooid() definition to a central place
1 parent b5a3883 commit 788af6f

File tree

12 files changed

+4
-23
lines changed

12 files changed

+4
-23
lines changed

contrib/lo/lo.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,6 @@
1414

1515
PG_MODULE_MAGIC;
1616

17-
#define atooid(x) ((Oid) strtoul((x), NULL, 10))
18-
1917

2018
/*
2119
* This is the trigger that protects us from orphaned large objects

contrib/vacuumlo/vacuumlo.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,6 @@
2424
#include "libpq-fe.h"
2525
#include "pg_getopt.h"
2626

27-
#define atooid(x) ((Oid) strtoul((x), NULL, 10))
28-
2927
#define BUFSIZE 1024
3028

3129
enum trivalue

src/backend/bootstrap/bootparse.y

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,8 +51,6 @@
5151
#include "tcop/dest.h"
5252
#include "utils/rel.h"
5353

54-
#define atooid(x) ((Oid) strtoul((x), NULL, 10))
55-
5654

5755
/*
5856
* Bison doesn't allocate anything that needs to live across parser calls,

src/backend/libpq/hba.c

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -52,9 +52,6 @@
5252
#endif
5353

5454

55-
#define atooid(x) ((Oid) strtoul((x), NULL, 10))
56-
#define atoxid(x) ((TransactionId) strtoul((x), NULL, 10))
57-
5855
#define MAX_TOKEN 256
5956
#define MAX_LINE 8192
6057

src/backend/nodes/readfuncs.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -164,8 +164,6 @@
164164
*/
165165
#define atoui(x) ((unsigned int) strtoul((x), NULL, 10))
166166

167-
#define atooid(x) ((Oid) strtoul((x), NULL, 10))
168-
169167
#define strtobool(x) ((*(x) == 't') ? true : false)
170168

171169
#define nullable_string(token,length) \

src/backend/utils/adt/misc.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,8 +44,6 @@
4444
#include "utils/builtins.h"
4545
#include "utils/timestamp.h"
4646

47-
#define atooid(x) ((Oid) strtoul((x), NULL, 10))
48-
4947

5048
/*
5149
* Common subroutine for num_nulls() and num_nonnulls().

src/bin/pg_basebackup/pg_basebackup.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,8 +39,6 @@
3939
#include "streamutil.h"
4040

4141

42-
#define atooid(x) ((Oid) strtoul((x), NULL, 10))
43-
4442
typedef struct TablespaceListCell
4543
{
4644
struct TablespaceListCell *next;

src/bin/pg_upgrade/pg_upgrade.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -97,8 +97,6 @@ extern char *output_files[];
9797
#define CLUSTER_NAME(cluster) ((cluster) == &old_cluster ? "old" : \
9898
(cluster) == &new_cluster ? "new" : "none")
9999

100-
#define atooid(x) ((Oid) strtoul((x), NULL, 10))
101-
102100
/* OID system catalog preservation added during PG 9.0 development */
103101
#define TABLE_SPACE_SUBDIRS_CAT_VER 201001111
104102
/* postmaster/postgres -b (binary_upgrade) flag added during PG 9.1 development */

src/bin/psql/common.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,6 @@
1313
#include "libpq-fe.h"
1414
#include "fe_utils/print.h"
1515

16-
#define atooid(x) ((Oid) strtoul((x), NULL, 10))
17-
1816
extern bool openQueryOutputFile(const char *fname, FILE **fout, bool *is_pipe);
1917
extern bool setQFout(const char *fname);
2018

src/bin/scripts/droplang.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,6 @@
1414
#include "common.h"
1515
#include "fe_utils/print.h"
1616

17-
#define atooid(x) ((Oid) strtoul((x), NULL, 10))
18-
1917

2018
static void help(const char *progname);
2119

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy