# File lib/rhc-common.rb, line 321
  def self.print_response_err(response)
    puts "Problem reported from server. Response code was #{response.code}."
    if (!@mydebug)
      puts "Re-run with -d for more information."
    end
    exit_code = 1
    if response.class.inspect == "Struct::FakeResponse"
      print_response_message(response.body)
    elsif response.content_type == 'application/json'
      begin
        json_resp = JSON.parse(response.body)
        exit_code = print_json_body(json_resp)
      rescue JSON::ParserError
        exit_code = 1
      end
    elsif @mydebug
      puts "HTTP response from server is #{response.body}"
    end
    exit exit_code.nil? ? 666 : exit_code
  end