Skip to content

Commit 0f62b30

Browse files
committed
Fix for \e on empty file.
1 parent 9bcf350 commit 0f62b30

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/bin/psql/psql.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*
88
*
99
* IDENTIFICATION
10-
* $Header: /cvsroot/pgsql/src/bin/psql/Attic/psql.c,v 1.108 1997/11/16 05:32:16 momjian Exp $
10+
* $Header: /cvsroot/pgsql/src/bin/psql/Attic/psql.c,v 1.109 1997/11/17 05:23:11 momjian Exp $
1111
*
1212
*-------------------------------------------------------------------------
1313
*/
@@ -2099,7 +2099,7 @@ MainLoop(PsqlSettings *pset, char *query, FILE *source)
20992099
* for next command
21002100
*/
21012101

2102-
if (line == NULL)
2102+
if (line == NULL || *line == '\0')
21032103
{ /* No more input. Time to quit, or \i done */
21042104
if (!pset->quiet)
21052105
printf("EOF\n");/* Goes on prompt line */

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy