fix cumsum, #2342