On the origin of the regioselectivity in glycosylation reactions of 1,2-diols.