From 520613dd07921f1f9c5f7577ff5dc8e2f95db900 Mon Sep 17 00:00:00 2001 From: =?utf8?q?David=20=E2=80=98Bombe=E2=80=99=20Roden?= Date: Wed, 13 Apr 2011 05:54:31 +0200 Subject: [PATCH] Cancel image insert when deleting a temporary image. --- src/main/java/net/pterodactylus/sone/core/Core.java | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/main/java/net/pterodactylus/sone/core/Core.java b/src/main/java/net/pterodactylus/sone/core/Core.java index f8cee11..7183063 100644 --- a/src/main/java/net/pterodactylus/sone/core/Core.java +++ b/src/main/java/net/pterodactylus/sone/core/Core.java @@ -1931,6 +1931,10 @@ public class Core implements IdentityListener, UpdateListener, ImageInsertListen synchronized (temporaryImages) { temporaryImages.remove(imageId); } + Image image = getImage(imageId, false); + if (image != null) { + imageInserter.cancelImageInsert(image); + } } /** -- 2.7.4