diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2013-10-22 19:40:26 -0400 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2013-10-22 19:40:26 -0400 |
commit | 2c66f9924c1162bfba27c77004ccf42fb6ea188d (patch) | |
tree | 920c20776ef6d13d7a5d3a836202d897abcaf428 /src/bin/psql/common.c | |
parent | 09a89cb5fc29b47c26d151e82293fd3bef592b7b (diff) | |
download | postgresql-2c66f9924c1162bfba27c77004ccf42fb6ea188d.tar.gz postgresql-2c66f9924c1162bfba27c77004ccf42fb6ea188d.zip |
Replace pg_asprintf() with psprintf().
This eliminates an awkward coding pattern that's also unnecessarily
inconsistent with backend coding. psprintf() is now the thing to
use everywhere.
Diffstat (limited to 'src/bin/psql/common.c')
-rw-r--r-- | src/bin/psql/common.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/bin/psql/common.c b/src/bin/psql/common.c index 71f0c8a95a8..bbdafab5e05 100644 --- a/src/bin/psql/common.c +++ b/src/bin/psql/common.c @@ -594,7 +594,7 @@ StoreQueryTuple(const PGresult *result) char *value; /* concate prefix and column name */ - pg_asprintf(&varname, "%s%s", pset.gset_prefix, colname); + varname = psprintf("%s%s", pset.gset_prefix, colname); if (!PQgetisnull(result, 0, i)) value = PQgetvalue(result, 0, i); @@ -1685,7 +1685,7 @@ expand_tilde(char **filename) { char *newfn; - pg_asprintf(&newfn, "%s%s", home, p); + newfn = psprintf("%s%s", home, p); free(fn); *filename = newfn; } |