]> granicus.if.org Git - postgresql/commitdiff
Fixes:
authorMarc G. Fournier <scrappy@hub.org>
Sun, 5 Jan 1997 23:46:17 +0000 (23:46 +0000)
committerMarc G. Fournier <scrappy@hub.org>
Sun, 5 Jan 1997 23:46:17 +0000 (23:46 +0000)
  This corrects the newline handling when using the readline library.

Submitted by: "Martin J. Laubach" <mjl@wwx.vip.at>

src/bin/psql/psql.c

index e217c268cdaefd1200e419a534d017b149f0c8e4..683f7663455ca9fee8dd12005d03456d58b25d71 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/bin/psql/Attic/psql.c,v 1.45 1997/01/02 07:07:32 momjian Exp $
+ *    $Header: /cvsroot/pgsql/src/bin/psql/Attic/psql.c,v 1.46 1997/01/05 23:46:17 scrappy Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -401,7 +401,10 @@ gets_noreadline(char *prompt, FILE * source)
 char           *
 gets_readline(char *prompt, FILE * source)
 {
-    return (readline(prompt));
+    char *s = readline(prompt);
+    fputc('\r', stdout);
+    fflush(stdout);
+    return s;
 }
 
 /*