From Universe::WithinJumpsImpl, rev. 4280:
retval.second = retval.first.size() - 1; // number of jumps is number of systems in path minus one for the starting system
The original distance returned was the number of vertices on the path, minus one, which equals the number of edges on the path. If no path was found at all, -1 was returned.
I don't know what johnson_shortest_paths returns for inaccessible nodes, I suppose some very high value, which should be ok as well for now. However, if a path was found, it returns the edge weight sum along the path, which in our case equals the number of edges on the path. This is the correct distance and so I think we can safely remove the "-1" from JumpDistance().update: additionally, the same computation has been performed in JumpsBetweenObjects(). Thus, the -1 has to be removed there as well!