Home | History | Annotate | Download | only in src

Lines Matching refs:tgt

435 subst(char *tgt, const char *oldstr, const char *newstr)
437 /* tgt is a malloc()d area... realloc() as necessary */
441 if ((word = strstrword(tgt, oldstr)) == NULL)
442 return tgt;
444 ltgt = strlen(tgt) + 1;
448 pos = word - tgt;
452 ntgt = realloc(tgt, ltgt += lnewstr - loldstr);
456 tgt = ntgt;
463 return tgt;
467 substip(char *tgt, const char *oldstr, struct in_addr ip)
469 return subst(tgt, oldstr, inet_ntoa(ip));
473 substlong(char *tgt, const char *oldstr, long l)
479 return subst(tgt, oldstr, buf);
483 substull(char *tgt, const char *oldstr, unsigned long long ull)
489 return subst(tgt, oldstr, buf);
495 substipv6(char *tgt, const char *oldstr, const struct ncpaddr *ip)
497 return subst(tgt, oldstr, ncpaddr_ntoa(ip));
502 substipv6prefix(char *tgt, const char *oldstr, const uint8_t *ipv6prefix)
512 return subst(tgt, oldstr, prefix);
1061 mkPrefix(int argc, char const *const *argv, char *tgt, int sz)
1068 tgt[tlen++] = ' ';
1072 strncpy(tgt+tlen, argv[f], len);
1075 tgt[tlen] = '\0';
1076 return tgt;