Catch possible NULL pointer on editing attribute list
authorAlan T. DeKok <aland@freeradius.org>
Tue, 15 Dec 2009 13:23:47 +0000 (14:23 +0100)
committerAlan T. DeKok <aland@freeradius.org>
Tue, 15 Dec 2009 14:16:47 +0000 (15:16 +0100)
src/main/evaluate.c

index fc86424..cbef0e3 100644 (file)
@@ -979,7 +979,7 @@ void radius_pairmove(REQUEST *request, VALUE_PAIR **to, VALUE_PAIR *from)
 
                found = FALSE;
                for (j = 0; j < to_count; j++) {
-                       if (edited[j] || !to_list[j]) continue;
+                       if (edited[j] || !to_list[j] || !from_list[i]) continue;
 
                        /*
                         *      Attributes aren't the same, skip them.