696. [bug] lwresd would die with an assertion failure when passed

a zero-length name.  [RT #692]
This commit is contained in:
Brian Wellington 2001-01-21 18:50:41 +00:00
parent 187a97287e
commit 76c9d2f6c0
3 changed files with 8 additions and 3 deletions

View file

@ -1,4 +1,7 @@
696. [bug] lwresd would die with an assertion failure when passed
a zero-length name. [RT #692]
695. [bug] If the resolver attempted to query a blackholed or
bogus server, the resolution would fail immediately.

View file

@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: lwdgabn.c,v 1.11 2001/01/09 21:39:50 bwelling Exp $ */
/* $Id: lwdgabn.c,v 1.12 2001/01/21 18:50:40 bwelling Exp $ */
#include <config.h>
@ -608,6 +608,8 @@ ns_lwdclient_processgabn(ns_lwdclient_t *client, lwres_buffer_t *b) {
b, &client->pkt, &req);
if (result != LWRES_R_SUCCESS)
goto out;
if (req->name == NULL || req->namelen == 0)
goto out;
isc_buffer_init(&namebuf, req->name, req->namelen);
isc_buffer_add(&namebuf, req->namelen);

View file

@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: lwdgrbn.c,v 1.7 2001/01/09 21:39:52 bwelling Exp $ */
/* $Id: lwdgrbn.c,v 1.8 2001/01/21 18:50:41 bwelling Exp $ */
#include <config.h>
@ -396,7 +396,7 @@ ns_lwdclient_processgrbn(ns_lwdclient_t *client, lwres_buffer_t *b) {
b, &client->pkt, &req);
if (result != LWRES_R_SUCCESS)
goto out;
if (req->name == NULL)
if (req->name == NULL || req->namelen == 0)
goto out;
client->options = 0;