Commit 5c99f9cd authored by Bruce Momjian's avatar Bruce Momjian

Fix MULTIBYTE handling in string by using strcat.

parent 219652d5
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
......@@ -26,7 +26,7 @@
#
#
# IDENTIFICATION
# $Header: /cvsroot/pgsql/src/bin/initdb/Attic/initdb.sh,v 1.69 1999/12/17 16:53:11 wieck Exp $
# $Header: /cvsroot/pgsql/src/bin/initdb/Attic/initdb.sh,v 1.70 1999/12/17 18:05:30 momjian Exp $
#
#-------------------------------------------------------------------------
......@@ -202,15 +202,27 @@ do
shift
done
if [ "$usage" ]; then
echo "$CMDNAME [-t|--template] [-d|--debug] [-n|--noclean] \\"
echo " [-u|--username SUPERUSER] [-D|--pgdata DATADIR] \\"
echo " [-L|--pglib=LIBDIR] [-e|--pgencoding=ENCODING]"
exit 0
echo ""
echo "Usage: $CMDNAME [options]"
echo ""
echo " -t, --template "
echo " -d, --debug "
echo " -n, --noclean "
echo " -i SYSID, --sysid=SYSID "
echo " -W PASSWORD, --password=PASSWORD "
echo " -u SUPERUSER, --username=SUPERUSER "
echo " -D DATADIR, --pgdata=DATADIR "
echo " -L LIBDIR, --pglib=LIBDIR "
if [ -n "$MULTIBYTE" ]; then
echo " -e ENCODING, --pgencoding=ENCODING"
fi
echo " -?, --help "
echo ""
exit 0
fi
#-------------------------------------------------------------------------
# Resolve the multibyte encoding name
#-------------------------------------------------------------------------
......
......@@ -317,11 +317,11 @@ listAllDbs(PsqlSettings *pset, bool desc)
strcpy(buf,
"SELECT pg_database.datname as \"Database\",\n"
" pg_user.usename as \"Owner\""
" pg_user.usename as \"Owner\"");
#ifdef MULTIBYTE
",\n pg_database.encoding as \"Encoding\""
strcat(buf,
",\n pg_database.encoding as \"Encoding\"");
#endif
);
if (desc)
strcat(buf, ",\n obj_description(pg_database.oid) as \"Description\"\n");
strcat(buf, "FROM pg_database, pg_user\n"
......
......@@ -8,7 +8,7 @@
#
#
# IDENTIFICATION
# $Header: /cvsroot/pgsql/src/bin/scripts/Attic/createlang.sh,v 1.3 1999/12/16 20:10:02 momjian Exp $
# $Header: /cvsroot/pgsql/src/bin/scripts/Attic/createlang.sh,v 1.4 1999/12/17 18:05:32 momjian Exp $
#
#-------------------------------------------------------------------------
......@@ -133,10 +133,10 @@ if [ "$usage" ]; then
echo " -h HOSTNAME, --host=HOSTNAME "
echo " -p PORT, --port=PORT "
echo " -U USERNAME, --username=USERNAME "
echo " -l, --list "
echo " -W, --password "
echo " -d DBNAME, --database=DBNAME "
echo " -e, --echo "
echo " -q, --quiet "
echo " -D PATH, --location=PATH "
echo " -L PGLIB --pglib=PGLIB "
echo " -?, --help "
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment