restore db fix. Allow dbname with $.

Terminal didn't allow $ without escape char.
This commit is contained in:
Anand Doshi 2011-08-05 17:43:53 +05:30
parent 68b1fe780b
commit 7627a051da

View file

@ -358,7 +358,7 @@ class DbManager:
mysql = mysql_path and os.path.join(mysql_path, 'mysql') or 'mysql'
try:
ret = os.system("%s -u root -p%s %s < %s"%(mysql, root_password.replace(" ", "\ "), target, source))
ret = os.system("%s -u root -p%s %s < %s"%(mysql, root_password.replace(" ", "\ "), target.replace("$", "\$"), source))
except Exception,e:
raise e