Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit31c8e94

Browse files
committed
Remove WIN32 defines. They never worked.
1 parentaaaba5a commit31c8e94

File tree

26 files changed

+39
-386
lines changed

26 files changed

+39
-386
lines changed

‎src/backend/libpq/pqcomm.c‎

Lines changed: 1 addition & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*
88
*
99
* IDENTIFICATION
10-
* $Header: /cvsroot/pgsql/src/backend/libpq/pqcomm.c,v 1.10 1996/12/26 22:07:03 momjian Exp $
10+
* $Header: /cvsroot/pgsql/src/backend/libpq/pqcomm.c,v 1.11 1997/02/14 04:15:29 momjian Exp $
1111
*
1212
*-------------------------------------------------------------------------
1313
*/
@@ -39,16 +39,12 @@
3939
#include<signal.h>
4040
#include<errno.h>
4141
#include<fcntl.h>
42-
#ifndefWIN32
4342
#include<unistd.h>/* for ttyname() */
4443
#include<sys/types.h>
4544
#include<sys/socket.h>
4645
#include<netdb.h>
4746
#include<netinet/in.h>
4847
#include<arpa/inet.h>
49-
#else
50-
#include<winsock.h>
51-
#endif/* WIN32 */
5248

5349
#if defined(linux)
5450
#ifndefSOMAXCONN
@@ -77,17 +73,8 @@ int PQAsyncNotifyWaiting;/* for async. notification */
7773
void
7874
pq_init(intfd)
7975
{
80-
#ifdefWIN32
81-
intin,out;
82-
83-
in=_open_osfhandle(fd,_O_RDONLY);
84-
out=_open_osfhandle(fd,_O_APPEND);
85-
Pfin=fdopen(in,"rb");
86-
Pfout=fdopen(out,"wb");
87-
#else
8876
Pfin=fdopen(fd,"r");
8977
Pfout=fdopen(dup(fd),"w");
90-
#endif/* WIN32 */
9178
if (!Pfin|| !Pfout)
9279
elog(FATAL,"pq_init: Couldn't initialize socket connection");
9380
PQnotifies_init();
@@ -487,26 +474,19 @@ pq_getinserv(struct sockaddr_in *sin, char *host, char *serv)
487474
void
488475
pq_regoob(void (*fptr)())
489476
{
490-
#ifdefWIN32
491-
/* Who knows what to do here? */
492-
return;
493-
#else
494477
intfd=fileno(Pfout);
495478
#if defined(hpux)
496479
ioctl(fd,FIOSSAIOOWN,getpid());
497480
#else/* hpux */
498481
fcntl(fd,F_SETOWN,getpid());
499482
#endif/* hpux */
500483
(void)pqsignal(SIGURG,fptr);
501-
#endif/* WIN32 */
502484
}
503485

504486
void
505487
pq_unregoob()
506488
{
507-
#ifndefWIN32
508489
pqsignal(SIGURG,SIG_DFL);
509-
#endif/* WIN32 */
510490
}
511491

512492

@@ -554,15 +534,6 @@ StreamServerPort(char *hostName, short portName, int *fdP)
554534
intfd;
555535
intone=1;
556536

557-
#ifdefWIN32
558-
/* This is necessary to make it possible for a backend to use
559-
** stdio to read from the socket.
560-
*/
561-
intoptionvalue=SO_SYNCHRONOUS_NONALERT;
562-
563-
setsockopt(INVALID_SOCKET,SOL_SOCKET,SO_OPENTYPE, (char*)&optionvalue,
564-
sizeof(optionvalue));
565-
#endif/* WIN32 */
566537

567538
if (!hostName)
568539
hostName="localhost";
@@ -648,10 +619,8 @@ StreamConnection(int server_fd, Port *port)
648619

649620
port->mask=1 <<port->sock;
650621

651-
#ifndefWIN32
652622
/* reset to non-blocking */
653623
fcntl(port->sock,F_SETFL,1);
654-
#endif/* WIN32 */
655624

656625
return(STATUS_OK);
657626
}

‎src/backend/libpq/pqpacket.c‎

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
*
99
*
1010
* IDENTIFICATION
11-
* $Header: /cvsroot/pgsql/src/backend/libpq/Attic/pqpacket.c,v 1.3 1997/02/13 08:06:36 scrappy Exp $
11+
* $Header: /cvsroot/pgsql/src/backend/libpq/Attic/pqpacket.c,v 1.4 1997/02/14 04:15:31 momjian Exp $
1212
*
1313
*-------------------------------------------------------------------------
1414
*/
@@ -38,13 +38,9 @@
3838
*/
3939
#include<stdio.h>
4040
#include<sys/types.h>
41-
#ifndefWIN32
4241
#include<sys/socket.h>
4342
#include<netdb.h>
4443
#include<netinet/in.h>
45-
#else
46-
#include<winsock.h>
47-
#endif/*WIN32 */
4844
#include<fcntl.h>
4945
#include<errno.h>
5046

‎src/backend/optimizer/path/costsize.c‎

Lines changed: 8 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*
88
*
99
* IDENTIFICATION
10-
* $Header: /cvsroot/pgsql/src/backend/optimizer/path/costsize.c,v 1.12 1997/01/26 16:06:42 scrappy Exp $
10+
* $Header: /cvsroot/pgsql/src/backend/optimizer/path/costsize.c,v 1.13 1997/02/14 04:15:35 momjian Exp $
1111
*
1212
*-------------------------------------------------------------------------
1313
*/
@@ -16,21 +16,15 @@
1616
#include"config.h"
1717

1818
#include<math.h>
19-
#ifdefWIN32
20-
# include<float.h>
19+
#ifdefHAVE_LIMITS_H
2120
# include<limits.h>
22-
# defineMAXINT INT_MAX
21+
# ifndefMAXINT
22+
# defineMAXINTINT_MAX
23+
# endif
2324
#else
24-
# ifdefHAVE_LIMITS_H
25-
# include<limits.h>
26-
# ifndefMAXINT
27-
# defineMAXINTINT_MAX
28-
# endif
29-
# else
30-
# ifdefHAVE_VALUES_H
31-
# include<values.h>
32-
# endif
33-
# endif
25+
# ifdefHAVE_VALUES_H
26+
# include<values.h>
27+
# endif
3428
#endif
3529

3630
#include<utils/lsyscache.h>

‎src/backend/optimizer/path/xfunc.c‎

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -9,16 +9,11 @@
99
*
1010
*
1111
* IDENTIFICATION
12-
* $Header: /cvsroot/pgsql/src/backend/optimizer/path/Attic/xfunc.c,v 1.2 1996/10/23 07:14:43 bryanh Exp $
12+
* $Header: /cvsroot/pgsql/src/backend/optimizer/path/Attic/xfunc.c,v 1.3 1997/02/14 04:15:39 momjian Exp $
1313
*
1414
*-------------------------------------------------------------------------
1515
*/
16-
#ifndefWIN32
1716
#include<math.h>/* for MAXFLOAT on most systems */
18-
#else
19-
#include<float.h>
20-
#defineMAXFLOAT DBL_MAX
21-
#endif/* WIN32 */
2217

2318
#include<values.h>/* for MAXFLOAT on SunOS */
2419
#include<string.h>

‎src/backend/parser/parser.c‎

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,15 +6,13 @@
66
*
77
*
88
* IDENTIFICATION
9-
* $Header: /cvsroot/pgsql/src/backend/parser/parser.c,v 1.17 1997/01/22 01:43:26 momjian Exp $
9+
* $Header: /cvsroot/pgsql/src/backend/parser/parser.c,v 1.18 1997/02/14 04:15:49 momjian Exp $
1010
*
1111
*-------------------------------------------------------------------------
1212
*/
1313
#include<string.h>
1414
#include<stdio.h>
15-
#ifndefWIN32
1615
#include<pwd.h>
17-
#endif/*WIN32 */
1816
#include<sys/param.h>/* for MAXPATHLEN */
1917

2018
#include"postgres.h"

‎src/backend/parser/scan.l‎

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,14 +8,12 @@
88
*
99
*
1010
* IDENTIFICATION
11-
* $Header: /cvsroot/pgsql/src/backend/parser/scan.l,v 1.8 1996/12/04 14:23:11 momjian Exp $
11+
* $Header: /cvsroot/pgsql/src/backend/parser/scan.l,v 1.9 1997/02/14 04:15:59 momjian Exp $
1212
*
1313
*-------------------------------------------------------------------------
1414
*/
1515
#include<ctype.h>
16-
#ifndef WIN32
1716
#include<unistd.h>
18-
#endif/* WIN32*/
1917
#ifndef __linux__
2018
#include<math.h>
2119
#else

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp