I don't think it's genetic but a learned behavior. It's a coping mechanism. Just like someone else might use drugs or alcohol in order to not deal with troubled relationships. It's another addictive behavior to some people. Sometimes, it's just a pattern that they don't know how to stop.