Free agent Jared Cunningham has agreed to a deal with the Cleveland Cavaliers, league sources told RealGM.

Cunningham recently committed to training camp with Cleveland, which drafted and traded him with the No. 24 selection in the 2012 NBA draft. He scored 10 points per game in eight contests with the Utah Jazz in the NBA summer league.

The Cavaliers remain hopeful to re-sign Tristan Thompson and J.R. Smith, with Cunningham competing for a final roster spot.

Cunningham, a 6-foot-4 guard, has played parts of four pro seasons with the Dallas Mavericks, Atlanta Hawks, Sacramento Kings and Los Angeles Clippers. After being waived by the Clippers, Cunningham finished the 2014-15 season in the D-League with Delaware and Idaho.

Cunningham has averaged 1.8 points and 4.9 minutes in 40 NBA appearances. He spent three seasons at Oregon State before declaring for the draft as a junior.