Correct Postgresql connection with space in password. Work around php bug
This commit is contained in:
parent
799e34acd4
commit
3b09aa8578
|
@ -128,6 +128,14 @@ class OC_DB {
|
||||||
}else{
|
}else{
|
||||||
$dsn='pgsql:dbname='.$name.';host='.$host;
|
$dsn='pgsql:dbname='.$name.';host='.$host;
|
||||||
}
|
}
|
||||||
|
/**
|
||||||
|
* Ugly fix for pg connections pbm when password use spaces
|
||||||
|
*/
|
||||||
|
$e_user = addslashes($user);
|
||||||
|
$e_password = addslashes($pass);
|
||||||
|
$pass = $user = null;
|
||||||
|
$dsn .= ";user='$e_user';password='$e_password'";
|
||||||
|
/** END OF FIX***/
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
try{
|
try{
|
||||||
|
|
Loading…
Reference in New Issue