This is the change I am least sure about: I stared at it for awhile, and it looks right to me, but to say I don't understand LSM cursors would be an understatement.

In short, the change is to call cursor->update for LSM update & remove operations, and cursor->insert only for LSM insert operations, where we previously always called cursor->insert regardless of the operation.