session2: handle stream end in the middle of the session

- use lock to ensure greenthread-safety

darcs-hash:20090429125614-b2873-8820735a831de5ff934eb62ab111f46846a34f14
support desktop stream in sip_session2 and session2

darcs-hash:20090429125717-b2873-97199a30a3c8f5321a61d2752d22750c1661f870