A lot vs. Alot: 9 Grammatical Pitfalls
defense mechanism n.
Any of a variety of usually unconscious mental processes used to protect oneself from shame, anxiety, loss of self-esteem, conflict, or other unacceptable feelings or thoughts, and including behaviors such as repression, projection, denial, and rationalization.
In psychology, a Freudian term referring to an unconscious avoidance of something that produces anxiety or some other unpleasant emotion. For example, someone who blots out the memory of a terrible accident is using a defense mechanism. Regression and sublimation are common defense mechanisms.