Locks or unlocks the buffer for modifications. If a buffer is locked, all modifications are blocked, not just user modifications.
Unless the edit is in the middle of an edit-sequence, this method calls lock-status-changed See also after-edit-sequence.