Where Silence Has Lease - S2-E2
Revealing mistake: When the black deck officer is supposed to be dead you can see the actor's nostrils flaring as he is breathing.
Where Silence Has Lease - S2-E2
Visible crew/equipment: As Picard approaches Data's position, the boom mike is reflected on the panel behind him.
Where Silence Has Lease - S2-E2
Continuity mistake: When Riker and Worf are beamed off the Yomato, Riker is on the left of Worf. When they materialize, Riker is on Worf's right.
Answer: Yes. The doors to the holodecks can be locked when in use by anyone aboard the Enterprise so they couldn't be disturbed. However, high ranking officers like Captain Picard could override the doors as it's seen that overrides are in use even for the crews quarters. Even Barclay, when he's indulging in one of his fantasies could have the doors to the holodeck unlocked by an override code.