Fix redstone doing infinite loops

Looks like the commit that fixed it was not correctly merged, so here it is.