Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 337606 Details for
Bug 454116
net-ftp/oftpd does not respect USE="-ipv6"
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch for broken non-IPv6 build.
oftpd-0.3.7-ipv4.patch (text/plain), 1.47 KB, created by
tallungulate
on 2013-02-01 16:53:57 UTC
(
hide
)
Description:
Patch for broken non-IPv6 build.
Filename:
MIME Type:
Creator:
tallungulate
Created:
2013-02-01 16:53:57 UTC
Size:
1.47 KB
patch
obsolete
>diff --git a/src/ftp_listener.c b/src/ftp_listener.c >index 0ac630d..3977078 100644 >--- a/src/ftp_listener.c >+++ b/src/ftp_listener.c >@@ -148,7 +148,7 @@ int ftp_listener_init(ftp_listener_t *f, > return 0; > } > >- assert(hp->h_length <= sizeof(sock_addr)); >+ daemon_assert(hp->h_length <= sizeof(sock_addr)); > memcpy(&sock_addr, hp->h_addr, hp->h_length); > } > #endif >@@ -489,7 +489,6 @@ static char *addr2string(const struct sockaddr *s) > > daemon_assert(s != NULL); > >-#ifdef INET6 > error = getnameinfo((struct sockaddr *)s, > sizeof(struct sockaddr_storage), > addr, >@@ -503,9 +502,6 @@ static char *addr2string(const struct sockaddr *s) > } else { > ret_val = addr; > } >-#else >- ret_val = inet_ntoa(s->sin_addr); >-#endif > > return ret_val; > } >diff --git a/src/ftp_session.c b/src/ftp_session.c >index 81e9c8e..7a1cbb1 100644 >--- a/src/ftp_session.c >+++ b/src/ftp_session.c >@@ -1957,11 +1957,16 @@ static int ip_equal(const struct sockaddr *a, const struct sockaddr *b) > > static int ip_equal(const struct sockaddr *a, const struct sockaddr *b) > { >+ struct sockaddr *aa, *bb; >+ > daemon_assert(a != NULL); > daemon_assert(b != NULL); > daemon_assert(a->sa_family == AF_INET); > daemon_assert(b->sa_family == AF_INET); > >+ aa = (struct sockaddr *)a; >+ bb = (struct sockaddr *)b; >+ > if (((struct sockaddr_in *)aa)->sin_addr.s_addr != > ((struct sockaddr_in *)bb)->sin_addr.s_addr) return 0; >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 454116
:
337604
| 337606