MILWAUKEE (AP) -- As conditioning tests go, this might have been a little bit more than Tyson Chandler was expecting in his first game back.
A double-overtime victory made the extra effort worthwhile.
Chandler played 36-plus minutes in his return from injury, J.R. Smith hit a go-ahead jumper in the second overtime and the New York Knicks beat the Milwaukee Bucks 107-101 on Wednesday night.
Chandler cramped up at the end of the game, earning him an apology of sorts from Knicks coach Mike Woodson.
''It's a sign of not being out on the floor and running,'' Woodson said. ''I apologized to him - but hell, I needed him.''
Chandler didn't mind at all.
''I was willing to do whatever it took to get a win,'' Chandler said. ''I told coach, don't put me on a minute restriction. Whatever you feel like you need or whenever you need me out there, just keep me out there.''
Carmelo Anthony scored 29 points and Beno Udrih added a season-high 21 for the Knicks. Smith had 19 points.
Anthony had the biggest workload of all, playing 55-plus minutes.
''We were right there and it kept going back-and-forth so we needed everybody to step up,'' Woodson said. ''I just didn't have time to rest him. That's how it's probably going to have to be for right now.''
Chandler, who had been out since Nov. 5 with a non-displaced fracture of his right fibula, had nine points and nine rebounds.
''Tyson came back strong,'' Anthony said. ''Just his presence out there. His awareness out there on the court, how to be aggressive, knowing when to be aggressive, when not to - his comeback was big for us.''
Brandon Knight scored a career-high 36 for the Bucks, who have lost four straight. John Henson had 20 points and 14 rebounds while Khris Middleton added 20 points.
Bucks coach Larry Drew praised Knight's scoring ability, but noted that he only had three assists - and the Bucks only had 13 as a team.
''We're going to have to be better, and he's going to have to be better, at distributing the basketball,'' Drew said.
Simply getting through a double-overtime game was a challenge for Drew, who had only eight healthy players.
''It's challenging,'' Drew said. ''I know a couple of our guys were gasping for air over there. But it certainly is an opportunity to see what they're made of.''
New York took a 99-98 lead on a jumper by Smith with 3:07 left in the second overtime. Anthony then hit a pair of free throws for a three-point lead with 1:32 left.
Knight missed a three-point attempt, giving the ball back to the Knicks, and Anthony hit a 3-pointer with 50.1 seconds left to put the game away.
Points were hard to come by late in the fourth quarter and in both overtimes, but both teams had chances.
The Bucks had a shot at the win with 19.2 seconds remaining in regulation but Henson and Middleton both missed, sending the game into overtime.
Drew made no secret of his annoyance with Henson deciding to take a long jumper, saying, ''That was not the shot. I'll just leave it at that.''
With the Knicks holding a two-point lead with 33.3 seconds left in the first overtime, Anthony missed a shot, Chandler grabbed the rebound and Andrea Bargnani missed, giving the ball back to the Bucks.
Henson then tipped in a wild Knight miss, tying the game with 0.3 of a second left and sending it into double overtime.
Bargnani's miss was a head-scratcher for Woodson.
''I don't know if he thought we were down,'' Woodson said. ''This is a game of inches and obviously he had something else going through his mind at the time.''
Chandler's return was a boost for a Knicks team that continues to struggle with injuries. Guard Pablo Prigioni was out with a toe fracture, and the Knicks were without Amar'e Stoudemire.
Rookie Giannis Antetokounmpo made his first career start for Milwaukee. Antetokounmpo got in early foul trouble, but recovered to score 10 points and grab seven rebounds.
NOTES: Guard O.J. Mayo was attending his grandmother's funeral and did not play for Milwaukee. ... Antetokounmpo is the youngest player to start a game in team history, and the youngest player to start an NBA game since Andrew Bynum in 2006, according to the Bucks' PR staff. ... Raymond Felton (strained left hamstring) did not dress and Kenyon Martin (strained abdominal muscle) did not make the trip for New York.