I
finally got hold of a different set of constants, and I'm happy to say that the converter is now scientifically accurate. Given the RA/Dec from an official star catalog, it produces the same galactic coordinates that the catalog shows :D
The error before was small, yes, but it irked me to no end.
Also, I discovered a grievous error in the conversion to cartesian coordinates. That is now working correctly as well, with X being the vector towards the galactic center, Y being the spinward vector, and Z being the vertical vector.
As this is an important bugfix, I hope it'll find its way to the archives soon :)