ringbuffer reorganization done; but CRASHES