So sorry to hear about your situation.
As Hox said, cocaine is a real relationship breaker, it completely changes people.
Hard as it is, you need to focus on you and ensure that you are putting yourself first. By no means am I saying you shouldn’t support him (specially if he is taking steps to deal with the issue) but don’t let it be at the expense of yourself or your child.
I have found through all of this that sometimes you too need to be selfish and put yourself first as they have done.
It’s so difficult where kids are involved too, I have 2 with my ex, and he has just this weekend suggested they “have a break” from each other even though it’s apparently not what he wants. He’s not prepared to admit he has a problem, so I’m lost as to what I can do to help him and them continue or rebuild any sort of relationship. If he doesn’t have a problem, he’s just an arsehole!!
I’m just focusing on me and my kids right now and hope you can do the same. This forum has really helped though and hopefully will help you through the tougher times x