Askia Booker scored 21 points and Josh Scott added 13 points and nine rebounds as the Buffaloes survived the Trojans’ upset bid in the first round of the Pac-12 tournament in Las Vegas.

Xavier Johnson had 11 points and Booker added seven rebounds for No. 5 seed Colorado (22-10), which advanced to face No. 4 seed California in Thursday’s quarterfinals after Byron Wesley’s 3-point shot at the buzzer bounced off the front rim. Wesley Gordon had eight points and six rebounds to help the Buffaloes defeat USC for the third time this season.

Wesley scored 23 points to lead No. 12 seed USC (11-21), while Omar Oraby had 10 points and seven rebounds. Pe’Shon Howard had seven points on 3-of-13 shooting for the Trojans, who lost 12 of their final 13 games under first-year coach Andy Enfield.

Colorado shot 52 percent in the first half and led 29-27 at the break, but the Trojans refused to go away and moved ahead 40-39 on Wesley’s 3-pointer with just over 13 minutes remaining. Wesley made eight of his 15 shots from the field for USC, which lost its fourth straight Pac-12 tournament game.

Howard scored with just under nine minutes left to give USC a 49-45 lead, but the Buffaloes held the Trojans without a field goal for nearly six minutes and used a 13-1 run to lead 58-50 with just over three minutes left. Wesley scored with 47 seconds remaining to cut the deficit to 59-56 and had a chance to tie after Julian Jacobs blocked Scott’s shot on the other end.

GAME NOTEBOOK: Colorado lost 66-65 in overtime in its only meeting this season against California on Saturday in Berkeley. … Jaron Hopkins had five rebounds for Colorado, which outrebounded the Trojans 38-27. … The Trojans, who missed 17 of their 22 shots from 3-point range, were outscored by an average of 11 points in league play.