Lines Matching defs:string
23 #include <string.h>
30 #include "string-util.h"
54 ret->string = memdup(variant->string, variant->size+1);
55 if (!ret->string)
84 free(variant->string);
124 free(p->string);
142 free(variant->string);
153 return variant->string;
195 if (p->type == JSON_VARIANT_STRING && streq(key, p->string))
763 static int json_tokens(const char *string, size_t size, JsonVariant ***tokens, size_t *n) {
772 assert(string);
778 buf = strndup(string, size);
806 var->string = strdup(rstr);
807 if (!var->string) {
852 int json_parse(const char *string, JsonVariant **rv) {
858 assert(string);
861 r = json_tokens(string, strlen(string), &s, &n);