remove all references to LogSocket.h
diff --git a/libcore/luni/src/main/native/org_apache_harmony_luni_platform_OSNetworkSystem.cpp b/libcore/luni/src/main/native/org_apache_harmony_luni_platform_OSNetworkSystem.cpp
index 6fc43b1..e36f618 100644
--- a/libcore/luni/src/main/native/org_apache_harmony_luni_platform_OSNetworkSystem.cpp
+++ b/libcore/luni/src/main/native/org_apache_harmony_luni_platform_OSNetworkSystem.cpp
@@ -39,7 +39,6 @@
 
 #include <cutils/properties.h>
 #include <cutils/adb_networking.h>
-#include <utils/LogSocket.h>
 #include "AndroidSystemNatives.h"
 
 // Temporary hack to build on systems that don't have up-to-date libc headers.
@@ -290,24 +289,6 @@
 }
 
 /**
- * Wrapper function for log_socket_connect, which is currently disabled.
- * TODO: either unbreak log_socket_connect and fix it to take strings or IP
- * addresses or remove it. After that, remove this function.
- *
- * @param fd the socket file descriptor to enable logging on
- * @param address pointer to the socket address the socket is connecting to
- */
-static void logSocketConnect(int fd, struct sockaddr_storage *address) {
-    // Since connection logging is disabled for now, don't implement IPv6
-    // support for it just yet.
-    if (address->ss_family == AF_INET) {
-        struct sockaddr_in *sin = (struct sockaddr_in *) address;
-        log_socket_connect(fd, ntohl(sin->sin_addr.s_addr),
-                ntohs(sin->sin_port));
-    }
-}
-
-/**
  * Returns the port number in a sockaddr_storage structure.
  *
  * @param address the sockaddr_storage structure to get the port from
@@ -862,7 +843,6 @@
                 }
 
             } else if (0 > result) {
-                log_socket_close(handle, result);
                 throwSocketException(env, result);
             }
             poll = 0;
@@ -879,7 +859,6 @@
 
                 continue; // try again
             } else if (0 > result) {
-                log_socket_close(handle, result);
                 throwSocketException(env, result);
             }
             poll = 0;
@@ -998,8 +977,6 @@
             // LOGD("-connect ret %d errno %d (via adb)", rc, errno);
 
         } else {
-            logSocketConnect(handle, &addr);
-
             /* set the socket to non-blocking */
             int block = JNI_TRUE;
             rc = ioctl(handle, FIONBIO, &block);
@@ -1659,11 +1636,9 @@
         return -1;
     } else if (ret == -1) {
         int err = convertError(errno);
-        log_socket_close(handle, err);
         throwSocketException(env, err);
         return 0;
     }
-    add_recv_stats(handle, ret);
     return ret;
 }
 
@@ -1726,7 +1701,6 @@
     result = send(handle, (jbyte *) message, (int) count, SOCKET_NOFLAGS);
     if (result < 0) {
         int err = convertError(errno);
-        log_socket_close(handle, err);
 
         if (SOCKERR_WOULDBLOCK == err){
             jclass socketExClass,errorCodeExClass;
@@ -1763,7 +1737,6 @@
         return 0;
     }
 
-    add_send_stats(handle, result);
     return result;
 }
 
@@ -1943,7 +1916,6 @@
         sockConnectWithTimeout(handle, address, 0, SOCKET_STEP_DONE, context);
         goto bail;
     } else if (result != SOCKERR_NOTCONNECTED) {
-        log_socket_close(handle, result);
         sockConnectWithTimeout(handle, address, 0, SOCKET_STEP_DONE,
                                context);
         /* we got an error other than NOTCONNECTED so we cannot continue */
@@ -1998,7 +1970,6 @@
             if (hasTimeout) {
                 remainingTimeout = finishTime - time_msec_clock();
                 if (remainingTimeout <= 0) {
-                    log_socket_close(handle, result);
                     sockConnectWithTimeout(handle, address, 0,
                             SOCKET_STEP_DONE, context);
                     jniThrowException(env,
@@ -2010,7 +1981,6 @@
                 remainingTimeout = 100;
             }
         } else {
-            log_socket_close(handle, result);
             sockConnectWithTimeout(handle, address, remainingTimeout,
                                    SOCKET_STEP_DONE, context);
             if ((SOCKERR_CONNRESET == result) ||
@@ -2131,7 +2101,6 @@
 
     if (ret < 0) {
         int err = convertError(errno);
-        log_socket_close(handle, err);
         throwSocketException(env, err);
         return;
     }
@@ -2161,7 +2130,6 @@
         } else if (SOCKERR_INTERRUPTED == result) {
             continue;
         } else if (0 > result) {
-            log_socket_close(handle, result);
             throwSocketException(env, result);
             return 0;
         }
@@ -2171,11 +2139,9 @@
 
     if (0 > result) {
         int err = convertError(errno);
-        log_socket_close(handle, err);
         throwSocketException(env, err);
         return 0;
     }
-    add_recv_stats(handle, result);
     return result;
 }
 
@@ -2214,7 +2180,6 @@
 
     if (ret < 0) {
         int err = convertError(errno);
-        log_socket_close(handle, err);
         throwSocketException(env, err);
         return;
     }
@@ -2274,7 +2239,6 @@
     result = send(handle, (jbyte *) &value, 1, MSG_OOB);
     if (result < 0) {
         int err = convertError(errno);
-        log_socket_close(handle, err);
         throwSocketException(env, err);
     }
 }
@@ -2292,14 +2256,11 @@
     if (ret < 0)  // Exception has already been thrown.
         return;
 
-    logSocketConnect(handle, &sockAddr);
-
     do {
         ret = connect(handle, (struct sockaddr *) &sockAddr, sizeof(sockAddr));
     } while (ret < 0 && errno == EINTR);
     if (ret < 0) {
         int err = convertError(errno);
-        log_socket_close(handle, err);
         throwSocketException(env, err);
     }
 }
@@ -2321,7 +2282,6 @@
      } while (result < 0 && errno == EINTR);
     if (result < 0) {
         int err = convertError(errno);
-        log_socket_close(handle, err);
         throwSocketException(env, err);
     }
 }
@@ -2350,7 +2310,6 @@
     } while (ret < 0 && errno == EINTR);
     if (ret < 0) {
         int err = convertError(errno);
-        log_socket_close(handle, err);
         jniThrowException(env, "java/net/BindException", netLookupErrorString(err));
         return 0;
     }
@@ -2384,7 +2343,6 @@
     } while (length < 0 && errno == EINTR);
     if (length < 0) {
         int err = convertError(errno);
-        log_socket_close(handle, err);
         throwSocketException(env, err);
         return 0;
     }
@@ -2394,7 +2352,6 @@
         return -1;
 
     port = getSocketAddressPort(&sockAddr);
-    add_recv_stats(handle, length);
     return port;
 }
 
@@ -2426,7 +2383,6 @@
     } while (actualLength < 0 && errno == EINTR);
     if (actualLength < 0) {
         int err = convertError(errno);
-        log_socket_close(handle, err);
         throwSocketException(env, err);
         return 0;
     }
@@ -2444,7 +2400,6 @@
         env->SetIntField(packet, gCachedFields.dpack_length,
                 (jint) actualLength);
     }
-    add_recv_stats(handle, actualLength);
     return (jint) actualLength;
 }
 
@@ -2503,7 +2458,6 @@
     if ( packet != NULL) {
         env->SetIntField(packet, gCachedFields.dpack_length, actualLength);
     }
-    add_recv_stats(handle, actualLength);
     return actualLength;
 }
 
@@ -2561,12 +2515,10 @@
                 || (SOCKERR_CONNECTION_REFUSED == err)) {
             return 0;
         } else {
-            log_socket_close(handle, err);
             throwSocketException(env, err);
             return 0;
         }
     }
-    add_send_stats(handle, result);
     return (jint) result;
 }
 
@@ -2603,12 +2555,10 @@
         if ((SOCKERR_CONNRESET == err) || (SOCKERR_CONNECTION_REFUSED == err)) {
             return 0;
         } else {
-            log_socket_close(handle, err);
             throwSocketException(env, err);
             return 0;
         }
     }
-    add_send_stats(handle, length);
     return result;
 }
 
@@ -2691,7 +2641,6 @@
      * to the Java input stream
      */
     if (0 < result) {
-        add_recv_stats(handle, result);
         return result;
     } else if (0 == result) {
         return -1;
@@ -2702,7 +2651,6 @@
                               netLookupErrorString(SOCKERR_TIMEOUT));
         } else {
             int err = convertError(errno);
-            log_socket_close(handle, err);
             throwSocketException(env, err);
         }
         return 0;
@@ -2746,7 +2694,6 @@
             }
             env->ReleaseByteArrayElements(data, message, 0);
             int err = convertError(result);
-            log_socket_close(handle, err);
             throwSocketException(env, err);
             return 0;
         }
@@ -2754,7 +2701,6 @@
     }
 
     env->ReleaseByteArrayElements(data, message, 0);
-    add_send_stats(handle, sent);
     return sent;
 }
 
@@ -2776,7 +2722,6 @@
 
     if (ret < 0) {
         int err = convertError(errno);
-        log_socket_close(handle, err);
         throwSocketException(env, err);
         return;
     }
@@ -2799,7 +2744,6 @@
 
     if (ret < 0) {
         int err = convertError(errno);
-        log_socket_close(handle, err);
         throwSocketException(env, err);
         return;
     }
@@ -2855,7 +2799,6 @@
         } while (result < 0 && errno == EINTR);
         if (result < 0) {
             int err = convertError(errno);
-            log_socket_close(handle, err);
             throwSocketException(env, err);
             free(message);
             return 0;
@@ -2865,7 +2808,6 @@
     }
 
     free(message);
-    add_send_stats(handle, sent);
     return sent;
 }
 
@@ -3483,8 +3425,6 @@
         return;
     }
 
-    log_socket_close(handle, SOCKET_CLOSE_LOCAL);
-
     jniSetFileDescriptorOfFD(env, fileDescriptor, -1);
 
     close(handle);
diff --git a/libcore/x-net/src/main/native/org_apache_harmony_xnet_provider_jsse_OpenSSLSocketImpl.cpp b/libcore/x-net/src/main/native/org_apache_harmony_xnet_provider_jsse_OpenSSLSocketImpl.cpp
index 250cf83..fd68460 100644
--- a/libcore/x-net/src/main/native/org_apache_harmony_xnet_provider_jsse_OpenSSLSocketImpl.cpp
+++ b/libcore/x-net/src/main/native/org_apache_harmony_xnet_provider_jsse_OpenSSLSocketImpl.cpp
@@ -36,8 +36,6 @@
 #include <openssl/rand.h>
 #include <openssl/ssl.h>
 
-#include <utils/LogSocket.h>
-
 #include "org_apache_harmony_xnet_provider_jsse_common.h"
 
 /**
@@ -693,7 +691,6 @@
         switch (error) {
              // Sucessfully read at least one byte.
             case SSL_ERROR_NONE: {
-                add_recv_stats(fd, result);
                 return result;
             }
 
@@ -861,7 +858,6 @@
             }
         }
     }
-    add_send_stats(fd, count);
     // LOGD("Successfully wrote %d bytes", count);
     
     return count;