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

Commit7411ec2

Browse files
committed
Undo changes for testlibpq2.c and isolationtester.c
1 parent38edca7 commit7411ec2

File tree

2 files changed

+8
-6
lines changed

2 files changed

+8
-6
lines changed

‎src/test/examples/testlibpq2.c

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,9 +34,11 @@
3434
#include<errno.h>
3535
#include<sys/time.h>
3636
#include<sys/types.h>
37+
#ifdefHAVE_SYS_SELECT_H
38+
#include<sys/select.h>
39+
#endif
3740

3841
#include"libpq-fe.h"
39-
#include"pg_socket.h"
4042

4143
staticvoid
4244
exit_nicely(PGconn*conn)
@@ -112,8 +114,7 @@ main(int argc, char **argv)
112114
FD_ZERO(&input_mask);
113115
FD_SET(sock,&input_mask);
114116

115-
if (pg_select(sock+1,&input_mask,NULL,NULL,NULL,
116-
PQisRsocket(conn))<0)
117+
if (select(sock+1,&input_mask,NULL,NULL,NULL)<0)
117118
{
118119
fprintf(stderr,"select() failed: %s\n",strerror(errno));
119120
exit_nicely(conn);

‎src/test/isolation/isolationtester.c

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,14 @@
1111
#include<windows.h>
1212
#endif
1313
#include<sys/time.h>
14+
#ifdefHAVE_SYS_SELECT_H
15+
#include<sys/select.h>
16+
#endif
1417

1518
#include"datatype/timestamp.h"
1619
#include"libpq-fe.h"
1720
#include"pqexpbuffer.h"
1821
#include"pg_getopt.h"
19-
#include"pg_socket.h"
2022

2123
#include"isolationtester.h"
2224

@@ -718,8 +720,7 @@ try_complete_step(Step *step, int flags)
718720
timeout.tv_sec=0;
719721
timeout.tv_usec=10000;/* Check for lock waits every 10ms. */
720722

721-
ret=pg_select(sock+1,&read_set,NULL,NULL,&timeout,
722-
PQisRsocket(conn));
723+
ret=select(sock+1,&read_set,NULL,NULL,&timeout);
723724
if (ret<0)/* error in select() */
724725
{
725726
if (errno==EINTR)

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp