mirror of
https://github.com/postgres/postgres.git
synced 2025-05-08 07:21:33 +03:00
psql: Remove one use of HAVE_UNIX_SOCKETS
This use was not protecting any unportable code, it was just omitting the code because it wouldn't be used. Remove the use to reduce code complexity a bit. Discussion: https://www.postgresql.org/message-id/flat/54bde68c-d134-4eb8-5bd3-8af33b72a010@2ndquadrant.com
This commit is contained in:
parent
b691c189c6
commit
541757f34e
@ -12,11 +12,6 @@
|
|||||||
#include <win32.h>
|
#include <win32.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef HAVE_UNIX_SOCKETS
|
|
||||||
#include <unistd.h>
|
|
||||||
#include <netdb.h>
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#include "common.h"
|
#include "common.h"
|
||||||
#include "common/string.h"
|
#include "common/string.h"
|
||||||
#include "input.h"
|
#include "input.h"
|
||||||
@ -147,7 +142,6 @@ get_prompt(promptStatus_t status, ConditionalStack cstack)
|
|||||||
if (*p == 'm')
|
if (*p == 'm')
|
||||||
buf[strcspn(buf, ".")] = '\0';
|
buf[strcspn(buf, ".")] = '\0';
|
||||||
}
|
}
|
||||||
#ifdef HAVE_UNIX_SOCKETS
|
|
||||||
/* UNIX socket */
|
/* UNIX socket */
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@ -158,7 +152,6 @@ get_prompt(promptStatus_t status, ConditionalStack cstack)
|
|||||||
else
|
else
|
||||||
snprintf(buf, sizeof(buf), "[local:%s]", host);
|
snprintf(buf, sizeof(buf), "[local:%s]", host);
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
/* DB server port number */
|
/* DB server port number */
|
||||||
|
Loading…
x
Reference in New Issue
Block a user