Index: /applications/editors/josm/plugins/measurement/src/org/openstreetmap/josm/plugins/measurement/MeasurementDialog.java
===================================================================
--- /applications/editors/josm/plugins/measurement/src/org/openstreetmap/josm/plugins/measurement/MeasurementDialog.java	(revision 32151)
+++ /applications/editors/josm/plugins/measurement/src/org/openstreetmap/josm/plugins/measurement/MeasurementDialog.java	(revision 32152)
@@ -295,5 +295,8 @@
     public void systemOfMeasurementChanged(String oldSoM, String newSoM) {
         // Refresh selection to take into account new system of measurement
-        selectionChanged(Main.main.getCurrentDataSet().getSelected());
+        DataSet currentDs = Main.main.getCurrentDataSet();
+        if (currentDs != null) {
+            selectionChanged(currentDs.getSelected());
+        }
     }
 }
