screenmarker: NPE check (#1938)

This commit is contained in:
Owain van Brakel
2019-11-08 01:55:44 +01:00
committed by Ganom
parent bed015e57c
commit 9aecf14686

View File

@@ -192,7 +192,7 @@ public class ScreenMarkerPlugin extends Plugin
public void finishCreation(boolean aborted)
{
if (!aborted)
if (!aborted && currentMarker != null)
{
final ScreenMarkerOverlay screenMarkerOverlay = new ScreenMarkerOverlay(currentMarker);
screenMarkerOverlay.setPreferredLocation(overlay.getBounds().getLocation());