Fix NullPointerException when tag.other is null

This commit is contained in:
Alex Birkett 2015-02-02 17:33:25 +01:00
parent 4b85dbc653
commit 103360c35e
1 changed files with 1 additions and 1 deletions

View File

@ -219,7 +219,7 @@ public class Solver {
if (row.coefficientFor(tag.marker) < 0.0)
return tag.marker;
}
if (tag.other.getType() == Symbol.Type.SLACK || tag.other.getType() == Symbol.Type.ERROR) {
if (tag.other != null && (tag.other.getType() == Symbol.Type.SLACK || tag.other.getType() == Symbol.Type.ERROR)) {
if (row.coefficientFor(tag.other) < 0.0)
return tag.other;
}