It's called compensation.
Main Entry: com·pen·sa·tion
Pronunciation: "käm-p&n-'sA-sh&n, -"pen-
Function: noun
1 a : the act of compensating : the state of being compensated b : correction of an organic defect or loss by hypertrophy or by increased functioning of another organ or unimpaired parts of the same organ c : a psychological mechanism by which feelings of inferiority, frustration, or failure in one field are counterbalanced by achievement in another