In general when working with ground glass joints (before they're stuck):
Ground glass joints are very sensitive to strong lye solutions. Whenever lye is about to get near ground glass joints, always grease them beforehand. The grease protects the fine surface structure of the ground glass from attack by the lye. It does not have to be fancy laboratory grade grease, regular petroleum jelly works fine. Apply only the thinnest amount and wipe off any excess with your fingers. As a confirmation that the joint is well-greased, it should turn almost transparent when the joints are fitted and pressed together. If any grease squeezes out, that is a sign that you used too much.
For the frozen joint that you are stuck with, I recommend the following:
- Apply ptfe lubricant (WD-40) to the joint. This has a very good ability to creep into the joint. If necessary, give it a few days to fully permeate the joint and apply more lubricant if needed. You can observe the progress by watching the joint turn clear where the spray moves in.
- Tap the joint from the side with a wooden spoon. Don't use metal, you'll chip or break the glass. Turn the joint while tapping it, to tap it at all angles. Tapping the outer part may help, but tapping the inner part is what you want most. Tap it from the side in such a way to make it move out of the other part. You obviously don't want to hammer it in any further.
- Heat with a heat gun or with a stream of hot water. Don't use a naked flame, especially so when the flask contains flammable liquids. You only want to apply the heat to the outer part of the joint, not to the inner part. The idea is that thermal expansion of the outer part will make it come apart from the unexpanded inner part. If you apply the heat to both parts, it doesn't work. Tapping as per the above point is also useful here.
Be careful when performing the above procedures. It is very easy to break the glass and spill the contents. Wear safety glasses and gloves. Wrap the flask in a plastic bag and then in another fabric bag. Keep it in or over a bucket to contain any spills