You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hc.apache.org by ol...@apache.org on 2019/05/30 09:47:45 UTC
[httpcomponents-client] branch master updated: Escape DEL character
when tracing
This is an automated email from the ASF dual-hosted git repository.
olegk pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/httpcomponents-client.git
The following commit(s) were added to refs/heads/master by this push:
new 91f9278 Escape DEL character when tracing
91f9278 is described below
commit 91f9278b9ab839665f2e66e8d823a96b38a0a136
Author: dowy <11...@users.noreply.github.com>
AuthorDate: Thu May 30 10:49:59 2019 +1200
Escape DEL character when tracing
DEL characters should be converted to [0x7f] in Wire traces otherwise they are difficult to see in logs.
---
httpclient5/src/main/java/org/apache/hc/client5/http/impl/Wire.java | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/httpclient5/src/main/java/org/apache/hc/client5/http/impl/Wire.java b/httpclient5/src/main/java/org/apache/hc/client5/http/impl/Wire.java
index e7db3fe..97d0392 100644
--- a/httpclient5/src/main/java/org/apache/hc/client5/http/impl/Wire.java
+++ b/httpclient5/src/main/java/org/apache/hc/client5/http/impl/Wire.java
@@ -93,7 +93,7 @@ public class Wire {
buffer.insert(0, header);
this.log.debug(this.id + " " + buffer.toString());
buffer.setLength(0);
- } else if ((ch < 32) || (ch > 127)) {
+ } else if ((ch < 32) || (ch >= 127)) {
buffer.append("[0x");
buffer.append(Integer.toHexString(ch));
buffer.append("]");