fr_value_box_t box;
char quote;
int offset = i + 1 + j;
+ fr_type_t type;
- if (cmd->syntax_types[j] == FR_TYPE_INVALID) {
+ /*
+ * May be written to for things like
+ * "combo_ipaddr".
+ */
+ type = cmd->syntax_types[j];
+
+ if (type == FR_TYPE_INVALID) {
continue;
}
quote = '\0';
- if (cmd->syntax_types[j] == FR_TYPE_STRING) {
+ if (type == FR_TYPE_STRING) {
if ((argv[offset][0] == '"') ||
(argv[offset][0] == '\'')) {
quote = argv[offset][0];
/*
* Parse the data to be sure it's well formed.
*/
- if (fr_value_box_from_str(NULL, &box, &cmd->syntax_types[j],
+ if (fr_value_box_from_str(NULL, &box, &type,
NULL, argv[offset], -1, quote, true) < 0) {
return -(offset);
}