Skip to content

Commit

Permalink
Proper return code check
Browse files Browse the repository at this point in the history
  • Loading branch information
alandekok committed Apr 20, 2014
1 parent bd793f9 commit eefa43e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/main/modcall.c
Expand Up @@ -652,7 +652,8 @@ static bool modcall_recurse(REQUEST *request, rlm_components_t component, int de
goto calculate_result;
}

if (radius_vpt_get_vp(&vp, request, g->vpt) <= 0) { /* nothing to loop over */
if ((radius_vpt_get_vp(&vp, request, g->vpt) < 0) || /* nothing to loop over */
!vp) {
MOD_LOG_OPEN_BRACE("foreach");
result = RLM_MODULE_NOOP;
MOD_LOG_CLOSE_BRACE();
Expand Down

0 comments on commit eefa43e

Please sign in to comment.