]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
in pairmake_any(), value may be NULL
authorAlan T. DeKok <aland@freeradius.org>
Sat, 23 Jan 2010 09:08:55 +0000 (10:08 +0100)
committerAlan T. DeKok <aland@freeradius.org>
Sat, 23 Jan 2010 09:09:16 +0000 (10:09 +0100)
src/lib/valuepair.c

index f6f4abcacfc7d6999718492d163cde422db4140a..6ea206b9c56d125930804b77e804036ebceeda50 100644 (file)
@@ -1355,6 +1355,9 @@ static VALUE_PAIR *pairmake_any(const char *attribute, const char *value,
                return NULL;
        }
 
+       vp->operator = (operator == 0) ? T_OP_EQ : operator;
+       if (!value) return vp;
+
        size = strlen(value + 2);
 
        /*
@@ -1397,8 +1400,6 @@ static VALUE_PAIR *pairmake_any(const char *attribute, const char *value,
                break;
        }
        
-       vp->operator = (operator == 0) ? T_OP_EQ : operator;
-
        return vp;
 }