I believe the following NBA rule may have applied in this situation (also it was a second technical):
Section V--Conduct
a. An official may assess a technical foul, without prior warning, at any time. A technical foul(s) may be assessed to any player on the court or anyone seated on the bench for conduct which, in the opinion of an official, is detrimental to the game. A technical foul cannot be assessed for physical contact when the ball is alive.
EXCEPTION: Fighting fouls and/or taunting with physical contact.
b. A maximum of two technicals for unsportsmanlike acts may be assessed any player, coach or trainer. Any of these offenders may be ejected for committing only one unsportsmanlike act, and they must be ejected for committing two unsports-manlike acts.
d. A technical foul shall be assessed for unsportsmanlike tactics such as:
(7) Taunting