This commit is contained in:
Kovid Goyal 2012-08-09 16:00:26 +05:30
parent 6c8c1d1d24
commit a486120c90

View File

@ -45,16 +45,16 @@ wpd_init(PyObject *self, PyObject *args) {
static PyObject * static PyObject *
wpd_uninit(PyObject *self, PyObject *args) { wpd_uninit(PyObject *self, PyObject *args) {
if (_com_initialized) {
CoUninitialize();
_com_initialized = 0;
}
if (portable_device_manager != NULL) { if (portable_device_manager != NULL) {
portable_device_manager->Release(); portable_device_manager->Release();
portable_device_manager = NULL; portable_device_manager = NULL;
} }
if (_com_initialized) {
CoUninitialize();
_com_initialized = 0;
}
Py_RETURN_NONE; Py_RETURN_NONE;
} }