MCPcopy Create free account
hub / github.com/F-Stack/f-stack / csv_leaf_set

Function csv_leaf_set

tools/libxo/encoder/csv/enc_csv.c:554–568  ·  view source on GitHub ↗

* Record a new value for a leaf */

Source from the content-addressed store, hash-verified

552 * Record a new value for a leaf
553 */
554static void
555csv_leaf_set (xo_handle_t *xop UNUSED, csv_private_t *csv, leaf_t *lp,
556 const char *value)
557{
558 xo_buffer_t *xbp = &csv->c_value_buf;
559
560 lp->f_value = xo_buf_offset(xbp);
561 lp->f_flags |= LF_HAS_VALUE;
562
563 char *cp = xo_buf_cur(xbp);
564 xo_buf_append(xbp, value, strlen(value) + 1);
565
566 csv_dbg(xop, csv, "csv: leaf: value: [%s] [%s] %x\n",
567 value, cp, lp->f_flags);
568}
569
570/*
571 * Record the requested set of leaf names. The input should be a set

Callers 1

csv_dataFunction · 0.85

Calls 4

xo_buf_offsetFunction · 0.85
xo_buf_curFunction · 0.85
xo_buf_appendFunction · 0.85
csv_dbgFunction · 0.85

Tested by

no test coverage detected