net/src/main/java/com/stanfy/enroscar/rest/request/net/PayloadPostConverter.java
protected void doSendWorkarounds(final URLConnection connection) {
    if (Build.VERSION.SDK_INT < Build.VERSION_CODES.GINGERBREAD && connection instanceof HttpURLConnection) {
      try {
        Field resHeaderField = connection.getClass().getDeclaredField("resHeader");
        resHeaderField.setAccessible(true);
        resHeaderField.set(connection, null);
      } catch (Exception e) {
        Log.w("Workaround", "Failed to make a wrokaround for Android 2.2", e);
      }
    }
  }
protected void doSendWorkarounds(final URLConnection connection) {
    if (Build.VERSION.SDK_INT < Build.VERSION_CODES.GINGERBREAD && connection instanceof HttpURLConnection) {
      try {
        Field resHeaderField = connection.getClass().getDeclaredField("resHeader");
        resHeaderField.setAccessible(true);
        resHeaderField.set(connection, null);
      } catch (Exception e) {
        Log.w("Workaround", "Failed to make a wrokaround for Android 2.2", e);
      }
    }
  }
protected void doSendWorkarounds ( final URLConnection connection ) { if ( Build . VERSION . SDK_INT < Build . VERSION_CODES . GINGERBREAD && connection instanceof HttpURLConnection ) { try { Field resHeaderField = connection . getClass ( ) . getDeclaredField ( "resHeader" ) ; resHeaderField . setAccessible ( true ) ; resHeaderField . set ( connection , null ) ; } catch ( Exception e ) { Log . w ( "Workaround" , "Failed to make a wrokaround for Android 2.2" , e ) ; } } }
Make workarounds for POST requests via {@link URLConnection} on older Android versions.
Override this method in order to disable them.
@param connection connection object instance
Make workarounds for POST requests via {