File: asyncns.c
Function: Asyncns_getaddrinfo
Error: dereferencing NULL (q->query) at asyncns.c:134
112 static AddrInfoQuery *Asyncns_getaddrinfo(Asyncns *self, PyObject *args, PyObject *kwds)
113 {
114 	char *host = NULL, *port = NULL;
115 	int family = AF_UNSPEC;
116 	static char *kwlist[] = {"host", "port", "family", "socktype", "proto", "flags", NULL};
117 	struct addrinfo hints;
118 	
119 	memset(&hints, 0, sizeof(hints));
120 	hints.ai_family   = AF_UNSPEC;
121 	hints.ai_socktype = 0;
122 	hints.ai_protocol = 0;
123 	hints.ai_flags    = 0;
124 	
125 	if(!PyArg_ParseTupleAndKeywords(args, kwds, "zz|iiii", kwlist, &host, &port,
126 	                                &hints.ai_family, &hints.ai_socktype,
when PyArg_ParseTupleAndKeywords() succeeds
taking False path
127 	                                &hints.ai_protocol, &hints.ai_flags))
128 	{
129 		/* exception is set by PyArg_ParseTupleAndKeywords */
130 		return NULL;
131 	}
132 	AddrInfoQuery *q = (AddrInfoQuery *)PyObject_MyNew(AddrInfoQuery_type);
133 	Query_store_asyncns(&q->query, self,
when call fails
134 	                    asyncns_getaddrinfo(self->asyncns, host, port, &hints));
dereferencing NULL (q->query) at asyncns.c:134
135 	asyncns_add_query(self, (Query*)q);
136 	return q;
137 }
138