Prevent indefinite hanging