Skip to content

Commit

Permalink
- explicitly specify IPPROTO_UDP when calling getaddrinfo().
Browse files Browse the repository at this point in the history
  • Loading branch information
keiichi committed Apr 24, 2003
1 parent 5d70e36 commit 9ee33d1
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions kame/kame/route6d/route6d.c
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/* $KAME: route6d.c,v 1.97 2003/04/22 09:55:37 itojun Exp $ */
/* $KAME: route6d.c,v 1.98 2003/04/24 12:26:19 keiichi Exp $ */

/*
* Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
Expand Down Expand Up @@ -30,7 +30,7 @@
*/

#ifndef lint
static char _rcsid[] = "$KAME: route6d.c,v 1.97 2003/04/22 09:55:37 itojun Exp $";
static char _rcsid[] = "$KAME: route6d.c,v 1.98 2003/04/24 12:26:19 keiichi Exp $";
#endif

#include <stdio.h>
Expand Down Expand Up @@ -617,6 +617,7 @@ init()
memset(&hints, 0, sizeof(hints));
hints.ai_family = PF_INET6;
hints.ai_socktype = SOCK_DGRAM;
hints.ai_protocol = IPPROTO_UDP;
hints.ai_flags = AI_PASSIVE;
error = getaddrinfo(NULL, port, &hints, &res);
if (error) {
Expand Down Expand Up @@ -671,6 +672,7 @@ init()
memset(&hints, 0, sizeof(hints));
hints.ai_family = PF_INET6;
hints.ai_socktype = SOCK_DGRAM;
hints.ai_protocol = IPPROTO_UDP;
error = getaddrinfo(RIP6_DEST, port, &hints, &res);
if (error) {
fatal("%s", gai_strerror(error));
Expand Down

0 comments on commit 9ee33d1

Please sign in to comment.