Commit 0d1b5c64 authored by Denis Bilenko's avatar Denis Bilenko

dnshelper.c: use PyImport_ImportModule instead of...

dnshelper.c: use PyImport_ImportModule instead of PyImport_InmportModuleNoBlock, the latter is not available in Python2.5
parent 500e0a8c
...@@ -19,7 +19,7 @@ get_socket_object(PyObject** pobject, const char* name, int incref) ...@@ -19,7 +19,7 @@ get_socket_object(PyObject** pobject, const char* name, int incref)
{ {
if (!*pobject) { if (!*pobject) {
PyObject* _socket; PyObject* _socket;
_socket = PyImport_ImportModuleNoBlock("_socket"); _socket = PyImport_ImportModule("_socket");
if (_socket) { if (_socket) {
*pobject = PyObject_GetAttrString(_socket, name); *pobject = PyObject_GetAttrString(_socket, name);
if (!*pobject) { if (!*pobject) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment