diff options
author | UbitUmarov | 2017-05-06 15:57:47 +0100 |
---|---|---|
committer | UbitUmarov | 2017-05-06 15:57:47 +0100 |
commit | ae191cd3042fec6b753b41b19907d236690a70cf (patch) | |
tree | aaaebcba691cef51e12e98af8b4b9d3d3b31c4bf /OpenSim/Capabilities/Handlers/GetTexture/GetTextureRobustHandler.cs | |
parent | fix a few wrong placement ( this is a test by the way ) (diff) | |
download | opensim-SC-ae191cd3042fec6b753b41b19907d236690a70cf.zip opensim-SC-ae191cd3042fec6b753b41b19907d236690a70cf.tar.gz opensim-SC-ae191cd3042fec6b753b41b19907d236690a70cf.tar.bz2 opensim-SC-ae191cd3042fec6b753b41b19907d236690a70cf.tar.xz |
dispose some MemoryStreams
Diffstat (limited to '')
-rw-r--r-- | OpenSim/Capabilities/Handlers/GetTexture/GetTextureRobustHandler.cs | 6 |
1 files changed, 0 insertions, 6 deletions
diff --git a/OpenSim/Capabilities/Handlers/GetTexture/GetTextureRobustHandler.cs b/OpenSim/Capabilities/Handlers/GetTexture/GetTextureRobustHandler.cs index d5df7a2..c339ec5 100644 --- a/OpenSim/Capabilities/Handlers/GetTexture/GetTextureRobustHandler.cs +++ b/OpenSim/Capabilities/Handlers/GetTexture/GetTextureRobustHandler.cs | |||
@@ -368,9 +368,6 @@ namespace OpenSim.Capabilities.Handlers | |||
368 | try | 368 | try |
369 | { | 369 | { |
370 | // Taking our jpeg2000 data, decoding it, then saving it to a byte array with regular data | 370 | // Taking our jpeg2000 data, decoding it, then saving it to a byte array with regular data |
371 | |||
372 | imgstream = new MemoryStream(); | ||
373 | |||
374 | // Decode image to System.Drawing.Image | 371 | // Decode image to System.Drawing.Image |
375 | if (OpenJPEG.DecodeToImage(texture.Data, out managedImage, out image) && image != null) | 372 | if (OpenJPEG.DecodeToImage(texture.Data, out managedImage, out image) && image != null) |
376 | { | 373 | { |
@@ -412,10 +409,7 @@ namespace OpenSim.Capabilities.Handlers | |||
412 | managedImage.Clear(); | 409 | managedImage.Clear(); |
413 | 410 | ||
414 | if (imgstream != null) | 411 | if (imgstream != null) |
415 | { | ||
416 | imgstream.Close(); | ||
417 | imgstream.Dispose(); | 412 | imgstream.Dispose(); |
418 | } | ||
419 | } | 413 | } |
420 | 414 | ||
421 | return data; | 415 | return data; |