    # File lib/fog/libvirt/compute.rb, line 116
            def enhance_uri(uri)
              require 'cgi'
              append=""

              # on macosx, chances are we are using libvirt through homebrew
              # the client will default to a socket location based on it's own location (/opt)
              # we conveniently point it to /var/run/libvirt/libvirt-sock
              # if no socket option has been specified explicitly

              if RUBY_PLATFORM =~ /darwin/
                querystring=::URI.parse(uri).query
                if querystring.nil?
                  append="?socket=/var/run/libvirt/libvirt-sock"
                else
                  if !::CGI.parse(querystring).has_key?("socket")
                    append="&socket=/var/run/libvirt/libvirt-sock"
                  end
                end
              end
              uri+append
            end