Bug fix: ring size = longest terminal chain + largest terminal chain