Merge branch 'dh/encoding-trace-optim'
An expensive operation to prepare tracing was done in re-encoding code path even when the tracing was not requested, which has been corrected. * dh/encoding-trace-optim: convert: return early when not tracingmaint
commit
3e12106370
|
@ -324,6 +324,9 @@ static void trace_encoding(const char *context, const char *path,
|
||||||
struct strbuf trace = STRBUF_INIT;
|
struct strbuf trace = STRBUF_INIT;
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
|
if (!trace_want(&coe))
|
||||||
|
return;
|
||||||
|
|
||||||
strbuf_addf(&trace, "%s (%s, considered %s):\n", context, path, encoding);
|
strbuf_addf(&trace, "%s (%s, considered %s):\n", context, path, encoding);
|
||||||
for (i = 0; i < len && buf; ++i) {
|
for (i = 0; i < len && buf; ++i) {
|
||||||
strbuf_addf(
|
strbuf_addf(
|
||||||
|
|
Loading…
Reference in New Issue