]> git.ipfire.org Git - thirdparty/postgresql.git/commitdiff
Fix error in termination of COPY IN mode when using V2 protocol.
authorTom Lane <tgl@sss.pgh.pa.us>
Sun, 14 Mar 2004 22:01:01 +0000 (22:01 +0000)
committerTom Lane <tgl@sss.pgh.pa.us>
Sun, 14 Mar 2004 22:01:01 +0000 (22:01 +0000)
Report and fix per ljb, 8-Mar-04.

src/interfaces/libpq/fe-exec.c

index 68474a79442990ca5c7bcd97b6e6e633c3365942..2b9549a714e5da0650bff607865f4225eada1115 100644 (file)
@@ -8,7 +8,7 @@
  *
  *
  * IDENTIFICATION
- *       $Header: /cvsroot/pgsql/src/interfaces/libpq/fe-exec.c,v 1.153.2.3 2004/03/05 01:54:13 tgl Exp $
+ *       $Header: /cvsroot/pgsql/src/interfaces/libpq/fe-exec.c,v 1.153.2.4 2004/03/14 22:01:01 tgl Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -1469,7 +1469,7 @@ PQputCopyEnd(PGconn *conn, const char *errormsg)
                {
                        /* Send old-style end-of-data marker */
                        if (pqPutMsgStart(0, false, conn) < 0 ||
-                               pqPuts("\\.\n", conn) < 0 ||
+                               pqPutnchar("\\.\n", 3, conn) < 0 ||
                                pqPutMsgEnd(conn) < 0)
                                return -1;
                }