Handle new CancellationExceptions being thrown by Bukkit Scheduler
This commit is contained in:
parent
c9ceafd127
commit
aefdab597b
1 changed files with 3 additions and 0 deletions
|
|
@ -10,6 +10,7 @@ import java.util.List;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
import java.util.Set;
|
import java.util.Set;
|
||||||
import java.util.concurrent.Callable;
|
import java.util.concurrent.Callable;
|
||||||
|
import java.util.concurrent.CancellationException;
|
||||||
import java.util.concurrent.Future;
|
import java.util.concurrent.Future;
|
||||||
|
|
||||||
import org.bukkit.ChatColor;
|
import org.bukkit.ChatColor;
|
||||||
|
|
@ -411,6 +412,8 @@ public class DynmapPlugin extends JavaPlugin implements DynmapAPI {
|
||||||
Boolean delay;
|
Boolean delay;
|
||||||
try {
|
try {
|
||||||
delay = f.get();
|
delay = f.get();
|
||||||
|
} catch (CancellationException cx) {
|
||||||
|
return null;
|
||||||
} catch (Exception ix) {
|
} catch (Exception ix) {
|
||||||
Log.severe(ix);
|
Log.severe(ix);
|
||||||
return null;
|
return null;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue