Dynamic headspace analyses of residual volatiles in pharmaceuticals