From ee0e16001c4073f770a134e7e18e89d3d2b9d7b4 Mon Sep 17 00:00:00 2001 From: Walter de Jong Date: Wed, 6 Aug 2014 16:55:57 +0200 Subject: clear the response Just making sure, it seems cleaner to make sure that the function can not exit with the response in some random/undefined state --- src/pam_radius_auth.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src') diff --git a/src/pam_radius_auth.c b/src/pam_radius_auth.c index 5ef44e0..c4b9fd1 100644 --- a/src/pam_radius_auth.c +++ b/src/pam_radius_auth.c @@ -779,6 +779,8 @@ static int talk_radius(radius_conf_t *conf, AUTH_HDR *request, AUTH_HDR *respons /* loop over all available servers */ while (server != NULL) { + /* clear the response */ + memset(response, 0, sizeof(AUTH_HDR)); /* only look up IP information as necessary */ if ((retval = host2server(server)) != PAM_SUCCESS) { -- cgit v1.2.3