Grab a hammer, a few scraps of wood, a large nail and a shim. Take them into the room and close the door. Stick the shim loosely between the door and the jamb to hold the door in position when you drive out the upper hinge pin.
How to Stop a Door From Swinging Open If the door frame is out of plumb you can stop the door from opening on it's own by putting a slight bend in the hinge pin.