diff options
Diffstat (limited to '')
-rw-r--r-- | OpenSim/Capabilities/Handlers/GetTexture/GetTextureHandler.cs | 5 |
1 files changed, 0 insertions, 5 deletions
diff --git a/OpenSim/Capabilities/Handlers/GetTexture/GetTextureHandler.cs b/OpenSim/Capabilities/Handlers/GetTexture/GetTextureHandler.cs index 062a842..e73cf9e 100644 --- a/OpenSim/Capabilities/Handlers/GetTexture/GetTextureHandler.cs +++ b/OpenSim/Capabilities/Handlers/GetTexture/GetTextureHandler.cs | |||
@@ -362,8 +362,6 @@ namespace OpenSim.Capabilities.Handlers | |||
362 | { | 362 | { |
363 | // Taking our jpeg2000 data, decoding it, then saving it to a byte array with regular data | 363 | // Taking our jpeg2000 data, decoding it, then saving it to a byte array with regular data |
364 | 364 | ||
365 | imgstream = new MemoryStream(); | ||
366 | |||
367 | // Decode image to System.Drawing.Image | 365 | // Decode image to System.Drawing.Image |
368 | if (OpenJPEG.DecodeToImage(texture.Data, out managedImage, out image) && image != null) | 366 | if (OpenJPEG.DecodeToImage(texture.Data, out managedImage, out image) && image != null) |
369 | { | 367 | { |
@@ -404,10 +402,7 @@ namespace OpenSim.Capabilities.Handlers | |||
404 | if(managedImage != null) | 402 | if(managedImage != null) |
405 | managedImage.Clear(); | 403 | managedImage.Clear(); |
406 | if (imgstream != null) | 404 | if (imgstream != null) |
407 | { | ||
408 | imgstream.Close(); | ||
409 | imgstream.Dispose(); | 405 | imgstream.Dispose(); |
410 | } | ||
411 | } | 406 | } |
412 | 407 | ||
413 | return data; | 408 | return data; |