mirror of
https://github.com/opensim/opensim.git
synced 2026-05-15 03:15:41 +08:00
Added temporary fix for the sqlite datastore exception in windows .Net, Added a Try catch block around "shapeDa.Fill(ds.Tables["primshapes"]);" line. Seems if the database file is empty (ie opensim has just created it or nothing has been stored in it yet.) then the exception will be fired and catch, then opensim can continue and have no problems (it will still save prims fine), then on next restart if the database file has entries in it, the exception will no longer be thrown.
This commit is contained in:
@@ -57,14 +57,23 @@ namespace OpenSim.DataStore.MonoSqliteStorage
|
||||
// TODO: see if the linkage actually holds.
|
||||
// primDa.FillSchema(ds, SchemaType.Source, "PrimSchema");
|
||||
TestTables(conn);
|
||||
|
||||
|
||||
ds.Tables.Add(createPrimTable());
|
||||
primDa.Fill(ds.Tables["prims"]);
|
||||
setupPrimCommands(primDa, conn);
|
||||
MainLog.Instance.Verbose("DATASTORE", "Populated Prim Definitions");
|
||||
|
||||
ds.Tables.Add(createShapeTable());
|
||||
shapeDa.Fill(ds.Tables["primshapes"]);
|
||||
|
||||
try
|
||||
{
|
||||
shapeDa.Fill(ds.Tables["primshapes"]);
|
||||
}
|
||||
catch (Exception)
|
||||
{
|
||||
MainLog.Instance.Verbose("DATASTORE", "Caught fill error on primshapes table");
|
||||
}
|
||||
|
||||
setupShapeCommands(shapeDa, conn);
|
||||
MainLog.Instance.Verbose("DATASTORE", "Populated Prim Shapes");
|
||||
|
||||
|
||||
Reference in New Issue
Block a user