Legal substances also have lots of information readily available around them - if I go to my pharmacy and ask for ibuprofen, they will tell me the dosages in advance. If I go to my doctor and they put me on oxycodone, they will give me a dose that they think is safe, (and in theory, a plan to reduce my dependence on them) without judgement. If you develop an opiod addiction, your support options are much more limited.
Also, Joplin took heroin AND massive quantities of alcohol on the day of her death. It will be close to saying that when someone dies in a car crash while DUI, driving is the real and unique problem here.
But the drug-war irrationality is better exposed by taking a look at weed and MDMA. Two quite safe substances (certainly more safe than alcohol), with clear medical applications, and forbidden just because some ignorant decided to put them in Schedule I. MDMA at the time of its prohibition was being used in psychotherapy with success in tens of thousands of patients [1]. Today, no medical use is recognized, and being in Schedule I (making it un-researchable), none will be. I wouldn't be too surprised that some country discover that it could be used as a treatment for depression or PTSD.
So heroin is actually pretty safe if used correctly.
Not many legal drugs has such short list of side effects.
People die when they over-dose (which more often than not happens because they don't know exactly what they're getting, or the purity of it) or mix with other substances that they shouldn't.
A person quits for a while, decides to start using again and shoots up their usual dose for which they no longer have sufficient tolerance.
If that person knew that this is a common way people end up killing themselves, they probably wouldn't make this mistake.