Removing assumption that SegNext returns segments in address order. See <https://info.ravenbrook.com/mail/2014/06/04/14-41-06/0/>.
Fixing wrong function name in comment.