A restart loop for use on OS X systems