/clear added and improved fail-safety