[Debugger] Use locking around use of pending_bes
[Debugger] Use locking around use of pending_bes

Should fix bug #7562

Unity-Technologies/debugger-libs,joj/debugger-libs,mono/debugger-libs,mono/debugger-libs,Unity-Technologies/debugger-libs,joj/debugger-libs