In recent FieldTrip versions we changed the behaviour for ft_componentanalysis to remove the balancing-matrix from the gradiometer structure. Accordingly we also changed the behaviour of other functions. If you have done an ICA before this change was introduced your data will most likely still contain the balancing-matrix, which will lead to crashes in certain functions pertaining to inferring the position of the channels. If you want to keep using your old data without redoing the ICA, a workaround for you is to to remove the balancing-matrix from your gradiometer information:
data.grad = rmfield(data.grad, 'balance');
If you have done this, everything should work fine again.