MCPcopy Create free account
hub / github.com/OpenSIPS/opensips / double2str

Function double2str

ut.h:307–317  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

305
306#define DOUBLE2STR_MAX_LEN INT2STR_MAX_LEN
307static inline char* double2str(double d, int* len)
308{
309 unsigned int buf;
310
311 buf = getstrbufindex();
312 *len = snprintf(int2str_buf[buf], INT2STR_MAX_LEN - 1, "%0.*lf",
313 FLOATING_POINT_PRECISION, d);
314 int2str_buf[buf][*len] = '\0';
315
316 return int2str_buf[buf];
317}
318
319#define BIGINT2STR_MAX_LEN INT2STR_MAX_LEN
320static inline char* bigint2str(long long l, int* len)

Callers 6

db_query_print_resultsFunction · 0.85
script_get_client_priceFunction · 0.85
script_get_vendor_priceFunction · 0.85
insert_in_cachedbFunction · 0.85
on_demand_loadFunction · 0.85

Calls 1

getstrbufindexFunction · 0.85

Tested by

no test coverage detected