Index: runtime/bin/secure_socket.cc |
diff --git a/runtime/bin/secure_socket.cc b/runtime/bin/secure_socket.cc |
index a2691347b1fe13ed795326da9aac3b81aeb773ee..25a93da26c22e58810e7fd9e22c31482432b50ae 100644 |
--- a/runtime/bin/secure_socket.cc |
+++ b/runtime/bin/secure_socket.cc |
@@ -6,9 +6,9 @@ |
#include <errno.h> |
#include <fcntl.h> |
-#include <sys/stat.h> |
#include <stdio.h> |
#include <string.h> |
+#include <sys/stat.h> |
#include <openssl/bio.h> |
#include <openssl/err.h> |
@@ -83,8 +83,7 @@ static void FetchErrorString(char* buffer, int length) { |
/* Handle an error reported from the BoringSSL library. */ |
static void ThrowIOException(int status, |
const char* exception_type, |
- const char* message, |
- bool free_message = false) { |
+ const char* message) { |
char error_string[SSL_ERROR_MESSAGE_BUFFER_SIZE]; |
FetchErrorString(error_string, SSL_ERROR_MESSAGE_BUFFER_SIZE); |
OSError os_error_struct(status, error_string, OSError::kBoringSSL); |
@@ -92,9 +91,6 @@ static void ThrowIOException(int status, |
Dart_Handle exception = |
DartUtils::NewDartIOException(exception_type, message, os_error); |
ASSERT(!Dart_IsError(exception)); |
- if (free_message) { |
- free(const_cast<char*>(message)); |
- } |
Dart_ThrowException(exception); |
UNREACHABLE(); |
} |