WT-5574 saw an issue with cursor copy debugging functionality, with a suggested enhancement of adding the ability for cursors to not participate in the feature.
A better solution might be to have a non-public flag on the cursor that indicates that this cursor is not participating in cursor copy. (Looking to the farther future, it's possible that after debug_mode=cursor_copy gets more use, we may in fact want to expose this as a feature on WT_SESSION->open_cursor configuration, there may be some odd corner cases for which the copying is inappropriate). This is a bigger change as I think you'd want the flag to be positive, i.e. WT_CURSTD_DEBUG_CURSOR_COPY, and turn it on once when the cursor is created if the connection flag was on, and then always check that flag in the cursor routines instead of the current way of checking the connection flag.
WT-5574 I made a minimal fix. This ticket is filed to address a more proper fix as Donald envisioned.