Sometimes legislation to reduce negative effects of one problem also improves the outcome for a related issue. In this case, states that legalized medicinal pot clocked fewer people dying from prescription pain medication overdoses, according to a new study published in Internal Medicine, a journal of the American Medical Association, reports CNN.com.

For the study, scientists reviewed pot laws and death certificates in all 50 states between 1999 and 2013, when just 13 states had passed medicinal marijuana legislation. Researchers found that, after medical marijuana laws kicked in, overdose deaths from prescription painkillers dropped by almost 25 percent.

What’s more, in 2010 alone, states that had passed medical marijuana laws saw about 1,700 fewer overdose deaths than they saw before these laws took effect.

But the scientists said the connection between medicinal pot laws and overdose deaths isn’t totally understood. The researchers also admitted the study had limitations. In particular, it’s possible that death certificates did not correctly classify overdose deaths. In addition, states have different requirements for reporting information about opioid painkillers.

Nonetheless, “we found that medical marijuana laws might provide unexpected benefits to public health,” said Marcus Bachhuber, MD, a primary care doctor at the Philadelphia Veterans Affairs Medical Center, and the study’s lead author. “As more states pass these laws, it will be important to continue collecting information to see if what we found may be happening in other states as well.”

Doctors are also concerned about another kind of pot. These synthetic cannabinoids are commonly called “spice,” “Scooby snacks” or “K2” on the streets. Click here to read more.