Fix merge bug

In the outer loop, wne changing the roles of "lo" and "hi" lists, do not use
the end-marker as a temporary as it is needed for the top of the next minor
loop