mirror of
https://github.com/postgres/postgres.git
synced 2025-11-24 00:23:06 +03:00
Cleanup
This commit is contained in:
@@ -106,10 +106,8 @@ typedef unsigned int ProtocolVersion;
|
||||
|
||||
#define PG_PROTOCOL(major, minor) (((major) << 16) | (minor))
|
||||
#define PG_PROTOCOL_LATEST PG_PROTOCOL(2, 0)
|
||||
#define PG_PROTOCOL_63 PG_PROTOCOL(1, 0)
|
||||
#define PG_PROTOCOL_62 PG_PROTOCOL(0, 0)
|
||||
|
||||
/* This startup packet is to support latest Postgres protocol (6.4, 6.3) */
|
||||
/* This startup packet is to support latest Postgres protocol */
|
||||
typedef struct _StartupPacket
|
||||
{
|
||||
ProtocolVersion protoVersion;
|
||||
@@ -121,18 +119,6 @@ typedef struct _StartupPacket
|
||||
} StartupPacket;
|
||||
|
||||
|
||||
/* This startup packet is to support pre-Postgres 6.3 protocol */
|
||||
typedef struct _StartupPacket6_2
|
||||
{
|
||||
unsigned int authtype;
|
||||
char database[PATH_SIZE];
|
||||
char user[NAMEDATALEN];
|
||||
char options[ARGV_SIZE];
|
||||
char execfile[ARGV_SIZE];
|
||||
char tty[PATH_SIZE];
|
||||
} StartupPacket6_2;
|
||||
|
||||
|
||||
/* Structure to hold all the connection attributes for a specific
|
||||
connection (used for both registry and file, DSN and DRIVER)
|
||||
*/
|
||||
@@ -157,12 +143,6 @@ typedef struct {
|
||||
char focus_password;
|
||||
} ConnInfo;
|
||||
|
||||
/* Macro to determine is the connection using 6.2 protocol? */
|
||||
#define PROTOCOL_62(conninfo_) (strncmp((conninfo_)->protocol, PG62, strlen(PG62)) == 0)
|
||||
|
||||
/* Macro to determine is the connection using 6.3 protocol? */
|
||||
#define PROTOCOL_63(conninfo_) (strncmp((conninfo_)->protocol, PG63, strlen(PG63)) == 0)
|
||||
|
||||
/*
|
||||
* Macros to compare the server's version with a specified version
|
||||
* 1st parameter: pointer to a ConnectionClass object
|
||||
|
||||
Reference in New Issue
Block a user