diff options
author | Noah Misch <noah@leadboat.com> | 2018-02-23 11:24:04 -0800 |
---|---|---|
committer | Noah Misch <noah@leadboat.com> | 2018-02-23 11:25:20 -0800 |
commit | a7eab4e1f6c8ef013b7997fa43f72ac32f81bdf3 (patch) | |
tree | df4ff50bf413fe14b72b70d2cbac675a3440e968 | |
parent | 71a0d0c5aad26642b58dcd8d5d2438411e08640e (diff) |
Synchronize doc/ copies of src/test/examples/.
This is mostly cosmetic, but it might fix build failures, on some
platform, when copying from the documentation.
Back-patch to 9.3 (all supported versions).
-rw-r--r-- | doc/src/sgml/libpq.sgml | 18 | ||||
-rw-r--r-- | src/test/examples/testlibpq2.sql | 2 |
2 files changed, 17 insertions, 3 deletions
diff --git a/doc/src/sgml/libpq.sgml b/doc/src/sgml/libpq.sgml index ada7d160050..4ea10bfc379 100644 --- a/doc/src/sgml/libpq.sgml +++ b/doc/src/sgml/libpq.sgml @@ -7779,13 +7779,16 @@ testlibpq.o(.text+0xa4): undefined reference to `PQerrorMessage' <programlisting> <![CDATA[ /* + * src/test/examples/testlibpq.c + * + * * testlibpq.c * * Test the C version of libpq, the PostgreSQL frontend library. */ #include <stdio.h> #include <stdlib.h> -#include <libpq-fe.h> +#include "libpq-fe.h" static void exit_nicely(PGconn *conn) @@ -7906,6 +7909,9 @@ main(int argc, char **argv) <programlisting> <![CDATA[ /* + * src/test/examples/testlibpq2.c + * + * * testlibpq2.c * Test of the asynchronous notification interface * @@ -7933,7 +7939,12 @@ main(int argc, char **argv) #include <string.h> #include <errno.h> #include <sys/time.h> -#include <libpq-fe.h> +#include <sys/types.h> +#ifdef HAVE_SYS_SELECT_H +#include <sys/select.h> +#endif + +#include "libpq-fe.h" static void exit_nicely(PGconn *conn) @@ -8044,6 +8055,9 @@ main(int argc, char **argv) <programlisting> <![CDATA[ /* + * src/test/examples/testlibpq3.c + * + * * testlibpq3.c * Test out-of-line parameters and binary I/O. * diff --git a/src/test/examples/testlibpq2.sql b/src/test/examples/testlibpq2.sql index fb7d3535073..1686c3ed0df 100644 --- a/src/test/examples/testlibpq2.sql +++ b/src/test/examples/testlibpq2.sql @@ -3,4 +3,4 @@ CREATE TABLE TBL1 (i int4); CREATE TABLE TBL2 (i int4); CREATE RULE r1 AS ON INSERT TO TBL1 DO -(INSERT INTO TBL2 VALUES (new.i); NOTIFY TBL2); + (INSERT INTO TBL2 VALUES (new.i); NOTIFY TBL2); |