do a max of 3 splits when first processing the nhibernate connect

strings so the ; in the db connect strings pass to the native
drivers correctly
0.6.0-stable
Sean Dague 2008-04-24 15:52:22 +00:00
parent c6f6218f60
commit 03c7055902
2 changed files with 2 additions and 2 deletions

View File

@ -59,7 +59,7 @@ namespace OpenSim.Data.NHibernate
{ {
// Split out the dialect, driver, and connect string // Split out the dialect, driver, and connect string
char[] split = {';'}; char[] split = {';'};
string[] parts = connect.Split(split); string[] parts = connect.Split(split, 3);
if (parts.Length != 3) { if (parts.Length != 3) {
// TODO: make this a real exception type // TODO: make this a real exception type
throw new Exception("Malformed Inventory connection string '" + connect + "'"); throw new Exception("Malformed Inventory connection string '" + connect + "'");

View File

@ -56,7 +56,7 @@ namespace OpenSim.Data.NHibernate
{ {
// Split out the dialect, driver, and connect string // Split out the dialect, driver, and connect string
char[] split = {';'}; char[] split = {';'};
string[] parts = connect.Split(split); string[] parts = connect.Split(split, 3);
if (parts.Length != 3) { if (parts.Length != 3) {
// TODO: make this a real exception type // TODO: make this a real exception type
throw new Exception("Malformed Inventory connection string '" + connect + "'"); throw new Exception("Malformed Inventory connection string '" + connect + "'");