It depends on the game system used and your choice. Most systems say that if it is stuck then it takes a strength roll (most fantasy games), a tech roll (alot of sci fi), or another type of roll to figure out how to open it. As a gm I usually don't worry about it unless it promotes the flow of the story.i.e the door is locked and the characters have to get in there to save the victim for the evil doer.