A frame-mounted decocker will always (if the gun is functioning properly) drop the hammer to a position where it cannot contact the firing pin. For example, SIG-Sauer pistols use what they call an "intercept notch" (just before it hits the fully forward position), and CZ drops the hammer to a sort of "one-third-cock" position. They will also usually drop the hammer in a more slow and controlled manner. On my CZ, sweeping the decocker down starts the hammer on the downward stroke, releasing the lever completes it, and the hammer drops slowly to the aforementioned position.
Slide-mounted safeties/decockers (e.g., "old-school" S&W metal-frames, Beretta) work differently. Although the hammer drops quite fast, there is a barrier between it and the firing pin, so again it cannot strike the firing pin. Again, this is if the gun is in good working order. (Early production Ruger P85s, which used this system, were recalled for firing when decocked.) You should always point the gun in a safe direction (and/or at something you don't care if you put a hole in) when decocking any pistol.