Skip to content

make conn_pool branch error (pgbench) #3

Closed
@digoal

Description

@digoal
make -C pgbench all
make[3]: Entering directory `/home/digoal/postgresql.builtin_pool/src/bin/pgbench'
gcc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement -Wendif-labels -Wmissing-format-attribute -Wformat-security -fno-strict-aliasing -fwrapv -fexcess-precision=standard -O2 -pthread -D_REENTRANT -D_THREAD_SAFE -D_POSIX_PTHREAD_SEMANTICS -I. -I. -I../../../src/interfaces/libpq -I../../../src/include  -D_GNU_SOURCE   -c -o pgbench.o pgbench.c
pgbench.c: In function ‘threadRun’:
pgbench.c:5208:24: warning: implicit declaration of function ‘alloc_socket_set’; did you mean ‘closesocket’? [-Wimplicit-function-declaration]
  socket_set *sockets = alloc_socket_set(nstate);
                        ^~~~~~~~~~~~~~~~
                        closesocket
pgbench.c:5208:24: warning: initialization makes pointer from integer without a cast [-Wint-conversion]
pgbench.c:5252:4: warning: implicit declaration of function ‘set_socket’; did you mean ‘setsockopt’? [-Wimplicit-function-declaration]
    set_socket(sockets, PQsocket(state[i].con), i);
    ^~~~~~~~~~
    setsockopt
pgbench.c:5274:3: warning: implicit declaration of function ‘clear_socket_set’; did you mean ‘closesocket’? [-Wimplicit-function-declaration]
   clear_socket_set(sockets, nstate);
   ^~~~~~~~~~~~~~~~
   closesocket
pgbench.c:5372:15: warning: implicit declaration of function ‘wait_on_socket_set’ [-Wimplicit-function-declaration]
      nsocks = wait_on_socket_set(sockets, nstate, maxsock, min_usec);
               ^~~~~~~~~~~~~~~~~~
pgbench.c:5413:9: warning: implicit declaration of function ‘error_on_socket’; did you mean ‘ferror_unlocked’? [-Wimplicit-function-declaration]
     if (error_on_socket(sockets, i, st->con))
         ^~~~~~~~~~~~~~~
         ferror_unlocked
pgbench.c:5416:9: warning: implicit declaration of function ‘ignore_socket’; did you mean ‘closesocket’? [-Wimplicit-function-declaration]
     if (ignore_socket(sockets, i, st->con))
         ^~~~~~~~~~~~~
         closesocket
pgbench.c:5554:2: warning: implicit declaration of function ‘free_socket_set’ [-Wimplicit-function-declaration]
  free_socket_set(sockets);
  ^~~~~~~~~~~~~~~
pgbench.c: At top level:
pgbench.c:5561:1: error: conflicting types for ‘alloc_socket_set’
 alloc_socket_set(int count)
 ^~~~~~~~~~~~~~~~
pgbench.c:5208:24: note: previous implicit declaration of ‘alloc_socket_set’ was here
  socket_set *sockets = alloc_socket_set(nstate);
                        ^~~~~~~~~~~~~~~~
pgbench.c:5567:1: warning: conflicting types for ‘free_socket_set’
 free_socket_set(socket_set *sa)
 ^~~~~~~~~~~~~~~
pgbench.c:5567:1: error: static declaration of ‘free_socket_set’ follows non-static declaration
pgbench.c:5554:2: note: previous implicit declaration of ‘free_socket_set’ was here
  free_socket_set(sockets);
  ^~~~~~~~~~~~~~~
pgbench.c:5573:1: error: conflicting types for ‘error_on_socket’
 error_on_socket(socket_set *sa, int idx, PGconn *con)
 ^~~~~~~~~~~~~~~
pgbench.c:5413:9: note: previous implicit declaration of ‘error_on_socket’ was here
     if (error_on_socket(sockets, i, st->con))
         ^~~~~~~~~~~~~~~
pgbench.c:5581:1: error: conflicting types for ‘ignore_socket’
 ignore_socket(socket_set *sa, int idx, PGconn *con)
 ^~~~~~~~~~~~~
pgbench.c:5416:9: note: previous implicit declaration of ‘ignore_socket’ was here
     if (ignore_socket(sockets, i, st->con))
         ^~~~~~~~~~~~~
pgbench.c:5587:1: warning: conflicting types for ‘clear_socket_set’
 clear_socket_set(socket_set *sa, int count)
 ^~~~~~~~~~~~~~~~
pgbench.c:5587:1: error: static declaration of ‘clear_socket_set’ follows non-static declaration
pgbench.c:5274:3: note: previous implicit declaration of ‘clear_socket_set’ was here
   clear_socket_set(sockets, nstate);
   ^~~~~~~~~~~~~~~~
pgbench.c:5593:1: warning: conflicting types for ‘set_socket’
 set_socket(socket_set *sa, int fd, int idx)
 ^~~~~~~~~~
pgbench.c:5593:1: error: static declaration of ‘set_socket’ follows non-static declaration
pgbench.c:5252:4: note: previous implicit declaration of ‘set_socket’ was here
    set_socket(sockets, PQsocket(state[i].con), i);
    ^~~~~~~~~~
pgbench.c:5599:1: error: static declaration of ‘wait_on_socket_set’ follows non-static declaration
 wait_on_socket_set(socket_set *sa, int nstate, int maxsock, int64 usec)
 ^~~~~~~~~~~~~~~~~~
pgbench.c:5372:15: note: previous implicit declaration of ‘wait_on_socket_set’ was here
      nsocks = wait_on_socket_set(sockets, nstate, maxsock, min_usec);
               ^~~~~~~~~~~~~~~~~~
pgbench.c:5599:1: warning: ‘wait_on_socket_set’ defined but not used [-Wunused-function]
 wait_on_socket_set(socket_set *sa, int nstate, int maxsock, int64 usec)
 ^~~~~~~~~~~~~~~~~~
pgbench.c:5593:1: warning: ‘set_socket’ defined but not used [-Wunused-function]
 set_socket(socket_set *sa, int fd, int idx)
 ^~~~~~~~~~
pgbench.c:5587:1: warning: ‘clear_socket_set’ defined but not used [-Wunused-function]
 clear_socket_set(socket_set *sa, int count)
 ^~~~~~~~~~~~~~~~
pgbench.c:5581:1: warning: ‘ignore_socket’ defined but not used [-Wunused-function]
 ignore_socket(socket_set *sa, int idx, PGconn *con)
 ^~~~~~~~~~~~~
pgbench.c:5573:1: warning: ‘error_on_socket’ defined but not used [-Wunused-function]
 error_on_socket(socket_set *sa, int idx, PGconn *con)
 ^~~~~~~~~~~~~~~
pgbench.c:5567:1: warning: ‘free_socket_set’ defined but not used [-Wunused-function]
 free_socket_set(socket_set *sa)
 ^~~~~~~~~~~~~~~
pgbench.c:5561:1: warning: ‘alloc_socket_set’ defined but not used [-Wunused-function]
 alloc_socket_set(int count)
 ^~~~~~~~~~~~~~~~
make[3]: *** [pgbench.o] Error 1
make[3]: Leaving directory `/home/digoal/postgresql.builtin_pool/src/bin/pgbench'
make[2]: *** [all-pgbench-recurse] Error 2
make[2]: Leaving directory `/home/digoal/postgresql.builtin_pool/src/bin'
make[1]: *** [all-bin-recurse] Error 2
make[1]: Leaving directory `/home/digoal/postgresql.builtin_pool/src'
make: *** [all-src-recurse] Error 2

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions