Skip to content

Commit 68824c4

Browse files
committed
Removing some debugging statements from Android cert verification.
1 parent 9bc05fb commit 68824c4

File tree

1 file changed

+0
-26
lines changed

1 file changed

+0
-26
lines changed

Release/src/http/client/x509_cert_utilities.cpp

Lines changed: 0 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -140,31 +140,6 @@ bool verify_X509_cert_chain(const std::vector<std::string> &certChain, const std
140140

141141
#if defined(ANDROID)
142142

143-
#include <android/log.h>
144-
145-
void android_print(const std::string &s)
146-
{
147-
//__android_log_print(ANDROID_LOG_WARN, "UnitTestpp", "%s", s.c_str());
148-
}
149-
150-
void printerror(JNIEnv *env)
151-
{
152-
jthrowable thr = env->ExceptionOccurred();
153-
if(thr != nullptr)
154-
{
155-
env->ExceptionClear();
156-
157-
jclass throwable_class = env->FindClass("java/lang/Throwable");
158-
jmethodID getMsg = env->GetMethodID(throwable_class,
159-
"getMessage",
160-
"()Ljava/lang/String;");
161-
162-
jstring str = static_cast<jstring>(env->CallObjectMethod(thr, getMsg));
163-
const char *charStr = env->GetStringUTFChars(str, 0);
164-
android_print(charStr);
165-
}
166-
}
167-
168143
/// <summary>
169144
/// Helper function to check return value and see if any exceptions
170145
/// occurred when calling a JNI function.
@@ -178,7 +153,6 @@ bool jni_failed(JNIEnv *env)
178153
// In the future if we improve error reporting the exception message
179154
// can be retrieved from here.
180155
env->ExceptionClear();
181-
//printerror(env); // TODO
182156
return true;
183157
}
184158
return false;

0 commit comments

Comments
 (0)