if (do_unescape) {
if (fr_value_box_from_str(ctx, &data, &data_type, NULL, in, inlen, quote) < 0) return 0;
- vpt = tmpl_alloc(ctx, TMPL_TYPE_UNPARSED, data.datum.strvalue, talloc_array_length(data.datum.strvalue) - 1, type);
+ vpt = tmpl_alloc(ctx, TMPL_TYPE_UNPARSED, data.datum.strvalue,
+ talloc_array_length(data.datum.strvalue) - 1, type);
talloc_free(data.datum.ptr);
} else {
vpt = tmpl_alloc(ctx, TMPL_TYPE_UNPARSED, in, inlen, type);
*/
if (do_unescape) {
if (fr_value_box_from_str(ctx, &data, &data_type, NULL, in,
- inlen, fr_token_quote[type]) < 0) return -1;
+ inlen, fr_token_quote[type]) < 0) return -1;
if (do_xlat) {
vpt = tmpl_alloc(ctx, TMPL_TYPE_XLAT, data.datum.strvalue,
talloc_array_length(data.datum.strvalue) - 1, type);
case T_BACK_QUOTED_STRING:
if (do_unescape) {
if (fr_value_box_from_str(ctx, &data, &data_type, NULL, in,
- inlen, fr_token_quote[type]) < 0) return -1;
+ inlen, fr_token_quote[type]) < 0) return -1;
- vpt = tmpl_alloc(ctx, TMPL_TYPE_EXEC, data.datum.strvalue, talloc_array_length(data.datum.strvalue) - 1, type);
+ vpt = tmpl_alloc(ctx, TMPL_TYPE_EXEC, data.datum.strvalue,
+ talloc_array_length(data.datum.strvalue) - 1, type);
talloc_free(data.datum.ptr);
} else {
vpt = tmpl_alloc(ctx, TMPL_TYPE_EXEC, in, inlen, type);
* Why do we pass a pointer to the tmpl type? Goddamn WiMAX.
*/
if (fr_value_box_from_str(vpt, &vpt->tmpl_value_box, &vpt->tmpl_fr_value_box_type,
- enumv, vpt->name, vpt->len, '\0') < 0) return -1;
+ enumv, vpt->name, vpt->len, '\0') < 0) return -1;
vpt->type = TMPL_TYPE_DATA;
break;
* @fixme We need a way of signalling xlat not to escape things.
*/
ret = fr_value_box_from_str(tmp_ctx, &tmp, &src_type, NULL,
- value.datum.strvalue, value.datum.length, '"');
+ value.datum.strvalue, value.datum.length, '"');
if (ret < 0) goto error;
value.datum.strvalue = tmp.datum.strvalue;