Fix messed up exception error printing
Reviewed By: boz
Test Plan: comes up in feed
git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@665107 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/lib/cpp/src/transport/TSocket.cpp b/lib/cpp/src/transport/TSocket.cpp
index 95781f0..32fc2e7 100644
--- a/lib/cpp/src/transport/TSocket.cpp
+++ b/lib/cpp/src/transport/TSocket.cpp
@@ -274,7 +274,9 @@
}
// Some other error, whatevz
- throw TTransportException(TTransportException::UNKNOWN, "ERROR:" + errno);
+ char buff[1024];
+ sprintf(buff, "ERROR errno: %d", errno);
+ throw TTransportException(TTransportException::UNKNOWN, buff);
}
// The remote host has closed the socket