• Home
  • Raw
  • Download

Lines Matching refs:len

39   size_t len;  member
91 ret->null.len = 1; in ebl_strtabinit()
101 morememory (struct Ebl_Strtab *st, size_t len) in morememory() argument
105 if (len < ps) in morememory()
106 len = ps; in morememory()
107 newmem = (struct memoryblock *) malloc (len); in morememory()
114 st->left = len - offsetof (struct memoryblock, memory); in morememory()
137 newstring (struct Ebl_Strtab *st, const char *str, size_t len) in newstring() argument
150 if (st->left < align + sizeof (struct Ebl_Strent) + len) in newstring()
152 if (morememory (st, sizeof (struct Ebl_Strent) + len)) in newstring()
161 newstr->len = len; in newstring()
166 for (i = len - 2; i >= 0; --i) in newstring()
167 newstr->reverse[i] = str[len - 2 - i]; in newstring()
168 newstr->reverse[len - 1] = '\0'; in newstring()
169 st->backp += align + sizeof (struct Ebl_Strent) + len; in newstring()
170 st->left -= align + sizeof (struct Ebl_Strent) + len; in newstring()
193 MIN ((*sep)->len, newstr->len) - 1); in searchstring()
206 ebl_strtabadd (struct Ebl_Strtab *st, const char *str, size_t len) in ebl_strtabadd() argument
212 if (len == 0) in ebl_strtabadd()
213 len = strlen (str) + 1; in ebl_strtabadd()
217 if (len == 1 && st->null.string != NULL) in ebl_strtabadd()
221 newstr = newstring (st, str, len); in ebl_strtabadd()
232 if ((*sep)->len > newstr->len) in ebl_strtabadd()
238 if (subs->len == newstr->len) in ebl_strtabadd()
250 st->backp -= newstr->len; in ebl_strtabadd()
251 st->left += newstr->len; in ebl_strtabadd()
256 else if ((*sep)->len != newstr->len) in ebl_strtabadd()
261 st->total += newstr->len - (*sep)->len; in ebl_strtabadd()
277 st->total += newstr->len; in ebl_strtabadd()
293 *freep = (char *) mempcpy (*freep, nodep->string, nodep->len); in copystrings()
294 *offsetp += nodep->len; in copystrings()
298 assert (subs->len < nodep->len); in copystrings()
299 subs->offset = nodep->offset + nodep->len - subs->len; in copystrings()