Skip to content

Commit 31fe394

Browse files
committed
Include catalog/pg_type.h instead of manually extracting the interesting
oid values.
1 parent a8dbe42 commit 31fe394

File tree

2 files changed

+4
-25
lines changed

2 files changed

+4
-25
lines changed

src/interfaces/python/mkdefines

Lines changed: 0 additions & 11 deletions
This file was deleted.

src/interfaces/python/pgmodule.c

Lines changed: 4 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -27,24 +27,14 @@
2727
*/
2828

2929
#include <Python.h>
30-
#include <postgres.h>
31-
#include <libpq-fe.h>
32-
#include <libpq/libpq-fs.h>
30+
#include "postgres.h"
31+
#include "libpq-fe.h"
32+
#include "libpq/libpq-fs.h"
33+
#include "catalog/pg_type.h"
3334
#include <stdio.h>
3435
#include <stdlib.h>
3536
#include <string.h>
3637

37-
/* really bad stuff here - I'm so naughty */
38-
/* If you need to you can run mkdefines to get */
39-
/* current defines but it should not have changed */
40-
#define INT2OID 21
41-
#define INT4OID 23
42-
#define OIDOID 26
43-
#define FLOAT4OID 700
44-
#define FLOAT8OID 701
45-
#define CASHOID 790
46-
#define NUMERICOID 1700
47-
4838
static PyObject *PGError;
4939
static const char *PyPgVersion = "3.2";
5040

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