From: David ‘Bombe’ Roden Date: Fri, 24 Jul 2015 04:27:07 +0000 (+0200) Subject: Don’t synchronize on Sone, it’s not a shared object anymore X-Git-Tag: 0.9.4^2~14 X-Git-Url: https://git.pterodactylus.net/?a=commitdiff_plain;h=4bcc656787f97e6f0a4680dab452b13bb6c77992;p=Sone.git Don’t synchronize on Sone, it’s not a shared object anymore --- diff --git a/src/main/java/net/pterodactylus/sone/core/SoneParser.java b/src/main/java/net/pterodactylus/sone/core/SoneParser.java index 2712bd3..ae1e2a5 100644 --- a/src/main/java/net/pterodactylus/sone/core/SoneParser.java +++ b/src/main/java/net/pterodactylus/sone/core/SoneParser.java @@ -325,16 +325,13 @@ public class SoneParser { } /* okay, apparently everything was parsed correctly. Now import. */ - /* atomic setter operation on the Sone. */ - synchronized (sone) { - sone.setProfile(profile); - sone.setPosts(posts); - sone.setReplies(replies); - sone.setLikePostIds(likedPostIds); - sone.setLikeReplyIds(likedReplyIds); - for (Album album : topLevelAlbums) { - sone.getRootAlbum().addAlbum(album); - } + sone.setProfile(profile); + sone.setPosts(posts); + sone.setReplies(replies); + sone.setLikePostIds(likedPostIds); + sone.setLikeReplyIds(likedReplyIds); + for (Album album : topLevelAlbums) { + sone.getRootAlbum().addAlbum(album); } return sone;