mirror of
https://github.com/opensim/opensim.git
synced 2026-05-15 03:15:41 +08:00
Changing the AssetBase constructors to avoid initializing assets with an unknown asset type, and log an error if it ever does happen
This commit is contained in:
@@ -311,11 +311,8 @@ namespace OpenSim.Region.CoreModules.Scripting.DynamicTexture
|
||||
}
|
||||
|
||||
// Create a new asset for user
|
||||
AssetBase asset = new AssetBase();
|
||||
asset.FullID = UUID.Random();
|
||||
AssetBase asset = new AssetBase(UUID.Random(), "DynamicImage" + Util.RandomClass.Next(1, 10000), (sbyte)AssetType.Texture);
|
||||
asset.Data = assetData;
|
||||
asset.Name = "DynamicImage" + Util.RandomClass.Next(1, 10000);
|
||||
asset.Type = 0;
|
||||
asset.Description = String.Format("URL image : {0}", Url);
|
||||
asset.Local = false;
|
||||
asset.Temporary = ((Disp & DISP_TEMP) != 0);
|
||||
|
||||
Reference in New Issue
Block a user