summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVincent Rubiolo2012-05-16 05:55:07 (EDT)
committer Eugene Tarassov2012-05-18 13:58:49 (EDT)
commitc19df67c818951693cbe9d1286baefd2db58b01b (patch)
tree85c03d67288decf4ae0a4afbb9d5229e324dd94c
parent172596e23c448b684a1ac61ee6305879f98d8d58 (diff)
downloadorg.eclipse.tcf.agent-c19df67c818951693cbe9d1286baefd2db58b01b.zip
org.eclipse.tcf.agent-c19df67c818951693cbe9d1286baefd2db58b01b.tar.gz
org.eclipse.tcf.agent-c19df67c818951693cbe9d1286baefd2db58b01b.tar.bz2
Leave spaces as is in TCF logger output.
Spaces were previously handled as non-printable characters which clobbered the TCF log output when data contained spaces. Leaving spaces unmodified greatly improves the TCF log readability. Note that the end of string character was also handled that way (i.e shown as a space). Changing it to an "<eos>" string so as to differentiate it from a normal space does not improve readability very much though so I have chosen to leave this previous behavior unchanged.
-rw-r--r--agent/tcf/framework/proxy.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/agent/tcf/framework/proxy.c b/agent/tcf/framework/proxy.c
index ea44dab..e5f389e 100644
--- a/agent/tcf/framework/proxy.c
+++ b/agent/tcf/framework/proxy.c
@@ -132,7 +132,9 @@ static void log_byte_func(int i) {
/* Printable ASCII */
log_chr(i);
}
- else if (i == 0) {
+ else if (i == 0 || i == ' ') {
+ /* Leave spaces as is for better log readibility */
+
log_chr(' ');
}
else if (i > 0) {