add a check for a cursor open in a modify operations.
Merge remote-tracking branch 'origin/master' into autotools