Lines Matching full:attributes
25 * attributes = [^,:\s]*
26 * entry = name[:attributes]
30 int (*callback)(const char *name, const char *attributes, void *priv), in env_attr_walk() argument
34 char *name, *attributes; in env_attr_walk() local
83 attributes = strchr(entry_cpy, ENV_ATTR_SEP); in env_attr_walk()
85 if (attributes != NULL) { in env_attr_walk()
87 *attributes++ = '\0'; in env_attr_walk()
88 /* remove white-space from attributes */ in env_attr_walk()
89 attributes = strim(attributes); in env_attr_walk()
98 retval = callback(name, attributes, priv); in env_attr_walk()
117 char *attributes; member
120 static int regex_callback(const char *name, const char *attributes, void *priv) in regex_callback() argument
135 if (!attributes) { in regex_callback()
147 free(cbp->attributes); in regex_callback()
148 cbp->attributes = malloc(strlen(attributes) + 1); in regex_callback()
149 if (cbp->attributes) { in regex_callback()
150 strcpy(cbp->attributes, attributes); in regex_callback()
167 * Retrieve the attributes string associated with a single name in the list
168 * There is no protection on attributes being too small for the value
170 int env_attr_lookup(const char *attr_list, const char *name, char *attributes) in env_attr_lookup() argument
172 if (!attributes) in env_attr_lookup()
184 priv.attributes = NULL; in env_attr_lookup()
190 strcpy(attributes, priv.attributes); in env_attr_lookup()
191 free(priv.attributes); in env_attr_lookup()
257 * Retrieve the attributes string associated with a single name in the list
258 * There is no protection on attributes being too small for the value
260 int env_attr_lookup(const char *attr_list, const char *name, char *attributes) in env_attr_lookup() argument
265 if (!attributes) in env_attr_lookup()
299 memcpy(attributes, entry, len); in env_attr_lookup()
301 attributes[len] = '\0'; in env_attr_lookup()