Bugzilla – Attachment 2623 Details for
Bug 2401
sshd copying options leaks memory
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
proposed patch
file_2401.txt (text/plain), 813 bytes, created by
Jakub Jelen
on 2015-05-20 16:38:27 AEST
(
hide
)
Description:
proposed patch
Filename:
MIME Type:
Creator:
Jakub Jelen
Created:
2015-05-20 16:38:27 AEST
Size:
813 bytes
patch
obsolete
>diff --git a/servconf.c b/servconf.c >index 9257a17..8e8029d 100644 >--- a/servconf.c >+++ b/servconf.c >@@ -1910,6 +1910,8 @@ copy_set_server_options(ServerOptions *dst, ServerOptions *src, int preauth) > dst->n = src->n; \ > } while (0) > >+ u_int i; >+ > M_CP_INTOPT(password_authentication); > M_CP_INTOPT(gss_authentication); > M_CP_INTOPT(rsa_authentication); >@@ -1947,8 +1949,10 @@ copy_set_server_options(ServerOptions *dst, ServerOptions *src, int preauth) > } while(0) > #define M_CP_STRARRAYOPT(n, num_n) do {\ > if (src->num_n != 0) { \ >+ for (i = 0; i < dst->num_n; i++) \ >+ free(dst->n[i]); \ > for (dst->num_n = 0; dst->num_n < src->num_n; dst->num_n++) \ >- dst->n[dst->num_n] = xstrdup(src->n[dst->num_n]); \ >+ dst->n[dst->num_n] = src->n[dst->num_n]; \ > } \ > } while(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 Raw
Actions:
View
Attachments on
bug 2401
: 2623