From 41bf4520231bb6454333d6acb1e011bfc9976bae Mon Sep 17 00:00:00 2001 From: Dean Troyer Date: Mon, 28 Jan 2013 14:04:39 -0600 Subject: [PATCH] Handle nested xtrace states The lib/database abstraction includes the appropriate database file that also contains the $XTRACE bits at entry and exit. The nested XTRACE handling overwrote the value from lib/database. So...make the nested files use their own XTRACE variables. Change-Id: Ibdfc8d7d1e1457a9bc889b781ce176b417789ea1 --- lib/databases/mysql | 4 ++-- lib/databases/postgresql | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/databases/mysql b/lib/databases/mysql index 952425365b..94aedc6409 100644 --- a/lib/databases/mysql +++ b/lib/databases/mysql @@ -5,7 +5,7 @@ # DATABASE_{HOST,USER,PASSWORD} must be defined # Save trace setting -XTRACE=$(set +o | grep xtrace) +MY_XTRACE=$(set +o | grep xtrace) set +o xtrace register_database mysql @@ -121,4 +121,4 @@ function database_connection_url_mysql { } # Restore xtrace -$XTRACE +$MY_XTRACE diff --git a/lib/databases/postgresql b/lib/databases/postgresql index 04db714afa..2c37f49b71 100644 --- a/lib/databases/postgresql +++ b/lib/databases/postgresql @@ -5,7 +5,7 @@ # DATABASE_{HOST,USER,PASSWORD} must be defined # Save trace setting -XTRACE=$(set +o | grep xtrace) +PG_XTRACE=$(set +o | grep xtrace) set +o xtrace register_database postgresql @@ -76,4 +76,4 @@ function database_connection_url_postgresql { } # Restore xtrace -$XTRACE +$PG_XTRACE