diff options
author | intrigeri <intrigeri@boum.org> | 2005-11-29 10:11:04 +0000 |
---|---|---|
committer | intrigeri <intrigeri@boum.org> | 2005-11-29 10:11:04 +0000 |
commit | fbd3c3d84c89f4d4ec31525d1793e186ab9d1f94 (patch) | |
tree | 0af84416c6c986117c47f39f1986d1c42fd4aed7 /handlers | |
parent | d56c0f0aeedc84560821bd3c57239476e12615ca (diff) | |
download | backupninja-fbd3c3d84c89f4d4ec31525d1793e186ab9d1f94.tar.gz backupninja-fbd3c3d84c89f4d4ec31525d1793e186ab9d1f94.tar.bz2 |
r3567@krups: intrigeri | 2005-11-17 22:08:30 +0100
pgsql.helper: forbid the user to choose an empty database set to backup
Diffstat (limited to 'handlers')
-rw-r--r-- | handlers/pgsql.helper | 36 |
1 files changed, 19 insertions, 17 deletions
diff --git a/handlers/pgsql.helper b/handlers/pgsql.helper index 1c8b4ef..aa807a5 100644 --- a/handlers/pgsql.helper +++ b/handlers/pgsql.helper @@ -7,23 +7,25 @@ do_pgsql_vserver() { } do_pgsql_databases() { - formBegin "$pgsql_title: databases" - formItem "Database:" - formItem "Database:" - formItem "Database:" - formItem "Database:" - formItem "Database:" - formItem "Database:" - formItem "Database:" - formItem "Database:" - formItem "Database:" - formItem "Database:" - formDisplay - [ $? = 1 ] && return - - pgsql_databases="databases = " - for i in $REPLY; do - [ "$i" != "" ] && pgsql_databases="$pgsql_databases $i" + REPLY= + while [ -z "$REPLY" ]; do + formBegin "$pgsql_title: databases" + formItem "Database:" + formItem "Database:" + formItem "Database:" + formItem "Database:" + formItem "Database:" + formItem "Database:" + formItem "Database:" + formItem "Database:" + formItem "Database:" + formItem "Database:" + formDisplay + [ $? = 0 ] || return 1 + pgsql_databases="databases = " + for i in $REPLY; do + [ -n "$i" ] && pgsql_databases="$pgsql_databases $i" + done done } |