The capsule that carries the passengers is programmed to detach itself from the rocket if there is any malfunction while launching.
The fully automated rocket will carry them to the edge of space. However, the spaceflights come with a risk, and the failure depends on how powerful the engine is. According to Joseph Fragola, who has worked in NASA, the possibility of failure in such flights should be around 1 in 1000. But Gary Lai, senior director of New Shepard's design, asserted in a Blue Origin video that the capsule is designed to get the passengers into safety in case of any mishap.
The New Shepard comes with an escape system tested 3 times by Blue Origin- once on the ground, once in mid-air, and once in space. In case the rocket fails, the emergency system will get activated and jettison the passengers to safety. Lai also said there is another backup system if the system fails.