A teenager who was jailed for violent disorder during the UK riots this summer is set to be released after a successful appeal.