Skip to content

Commit d7a06c2

Browse files
committed
Fix psql \x by removing puts().
Greg Sabino Mullane
1 parent a3b9c69 commit d7a06c2

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/bin/psql/print.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
*
44
* Copyright (c) 2000-2005, PostgreSQL Global Development Group
55
*
6-
* $PostgreSQL: pgsql/src/bin/psql/print.c,v 1.72 2005/07/18 20:57:53 momjian Exp $
6+
* $PostgreSQL: pgsql/src/bin/psql/print.c,v 1.73 2005/09/22 15:51:51 momjian Exp $
77
*/
88
#include "postgres_fe.h"
99
#include "common.h"
@@ -570,7 +570,7 @@ print_aligned_vertical(const char *title, const char *const *headers,
570570

571571
if (cells[0] == NULL)
572572
{
573-
puts(_("(No rows)\n"));
573+
fprintf(fout, _("(No rows)\n"));
574574
return;
575575
}
576576

@@ -704,7 +704,7 @@ print_aligned_vertical(const char *title, const char *const *headers,
704704
if (opt_align[i % col_count] == 'r' && opt_numeric_locale)
705705
format_numeric_locale(my_cell);
706706
if (opt_border < 2)
707-
puts(my_cell);
707+
fprintf(fout, "%s\n", my_cell);
708708
else
709709
fprintf(fout, "%-s%*s |\n", my_cell, dwidth - cell_w[i], "");
710710
free(my_cell);

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