Can you try this ? :
1 - Switch Audio Method to "htcflag".
2 - Reboot.
3 - Start my app. There should be no audio.
4 - See if phone audio works.
5 - Stop my app.
6 - See if phone audio works.
"htcflag" should do nothing and be benign on Samsung. If phone audio is stll broken, then something besides audio routing code is breaking it. (But I doubt this.)
sfu_sdcs SHOULD work on CM7 for any device that supports the CM FM app. So it might be interfering. But I couldn't get sfu_sdcs working.
I read on the CM7 nightly thread for Galaxy S yesterday that the CM FM app is expected to be fixed soon. I hope there will be fixes for libaudio / sfu_sdcs. Regardless, if the CM FM app works OK, I can check the source and make my app work OK too.
the cm7 fm app is fixed by some kernel fixes afaik, but i doubt that they make it into fugumod, as that one is realy far from stock, it is 2.6.36 now and nika is working hard towards 2.6.37 stock cm7 is 188.8.131.52 or something iirc
edit: you are right, its working with htcflag.