Skip to content

Commit cd1923e

Browse files
author
jantje
committed
#527 handle null case
1 parent 2a28c7e commit cd1923e

File tree

1 file changed

+7
-5
lines changed

1 file changed

+7
-5
lines changed

it.baeyens.arduino.core/src/io/sloeber/core/api/BoardID.java

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -324,11 +324,13 @@ private void getMenuOptions(ICConfigurationDescription confdesc) {
324324
e.printStackTrace();
325325
return;
326326
}
327-
String[] lines = storedValue.split("\n"); //$NON-NLS-1$
328-
for (String curLine : lines) {
329-
String[] values = curLine.split("=", 2); //$NON-NLS-1$
330-
if (values.length == 2) {
331-
this.myOptions.put(values[0], values[1]);
327+
if (storedValue != null) {
328+
String[] lines = storedValue.split("\n"); //$NON-NLS-1$
329+
for (String curLine : lines) {
330+
String[] values = curLine.split("=", 2); //$NON-NLS-1$
331+
if (values.length == 2) {
332+
this.myOptions.put(values[0], values[1]);
333+
}
332334
}
333335
}
334336

0 commit comments

Comments
 (0)