It happened in Frankfurt (Hessen), not Bavaria, you're probably referring to the Gustl Mollath case -- which is eerily similar. You're right its not a systemic issue I think (I hope), but it sheds light on the role of psychiatric "experts" in court proceedings and how corruptible they can be in some cases.