MCPcopy Create free account
hub / github.com/acl-dev/acl / tpl_set_field_fmt_global

Function tpl_set_field_fmt_global

app/wizard/tpllib.cpp:825–847  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

823}
824
825void tpl_set_field_fmt_global(tpl_t* tpl, const char* key, const char* fmt, ...)
826{
827 int n;
828 int len = 256;
829 char *buf = (char*)acl_mymalloc(len);
830
831 while (1)
832 {
833 va_list ap;
834
835 va_start(ap, fmt);
836 n = vsnprintf(buf, len, fmt, ap);
837 va_end(ap);
838
839 if (n > -1 && n < len)
840 break;
841
842 len *= 2;
843 buf = (char*) acl_myrealloc(buf, len);
844 }
845 tpl_set_field_global(tpl, key, buf, n);
846 acl_myfree(buf);
847}
848
849void tpl_set_field_int_global(tpl_t* tpl, const char* key, int val)
850{

Callers 2

set_cookiesFunction · 0.70
copy_and_replaceMethod · 0.70

Calls 1

tpl_set_field_globalFunction · 0.70

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…