From: Simo Sorce Date: Thu, 14 Jan 2016 15:24:17 +0000 (-0500) Subject: Fix potential loop when requesting attribute data. X-Git-Tag: v1.3.2~5 X-Git-Url: http://www.project-moonshot.org/gitweb/?p=mod_auth_gssapi.git;a=commitdiff_plain;h=7c0d8634541da5804f711a0e777b3ab03e897911 Fix potential loop when requesting attribute data. If this function fail we are better off abandoning the whole quest, continueing here may end us up in an infinite loop where the fucntion keeps failing w/o changing attr.more Thanks to Alejandro Perez for finding this flaw. Signed-off-by: Simo Sorce --- diff --git a/src/environ.c b/src/environ.c index 1ea72e0..f9bbf30 100644 --- a/src/environ.c +++ b/src/environ.c @@ -214,7 +214,7 @@ void mag_get_name_attributes(request_rec *req, struct mag_config *cfg, attr.value = empty_buffer; attr.display_value = empty_buffer; - if (!mag_get_name_attr(req, name, &attr)) continue; + if (!mag_get_name_attr(req, name, &attr)) break; if (cfg->name_attributes->output_json) { mag_add_json_name_attr(req, i == 0, &attr, &json);