The phrase "an accident waiting to happen" refers to a person or thing that is dangerous or unsafe. For example, a very clumsy person and a rickety ladder might both be referred to as "an accident waiting to happen."