Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • protocols/jabber/io.c

    r96f954d r06b5893  
    276276}
    277277
    278 gboolean jabber_connected_ssl( gpointer data, int returncode, void *source, b_input_condition cond )
     278gboolean jabber_connected_ssl( gpointer data, void *source, b_input_condition cond )
    279279{
    280280        struct im_connection *ic = data;
     
    292292                jd->ssl = NULL;
    293293               
    294                 if( returncode != 0 )
    295                 {
    296                         char *err = ssl_verify_strerror( returncode );
    297                         imcb_error( ic, "Certificate verification problem 0x%x: %s",
    298                                     returncode, err ? err : "Unknown" );
    299                         g_free( err );
    300                         imc_logout( ic, FALSE );
    301                 }
    302                 else
    303                 {
    304                         imcb_error( ic, "Could not connect to server" );
    305                         imc_logout( ic, TRUE );
    306                 }
    307                
     294                imcb_error( ic, "Could not connect to server" );
     295                imc_logout( ic, TRUE );
    308296                return FALSE;
    309297        }
     
    409397        struct im_connection *ic = data;
    410398        struct jabber_data *jd = ic->proto_data;
    411         char *xmlns, *tlsname;
     399        char *xmlns;
    412400       
    413401        xmlns = xt_find_attr( node, "xmlns" );
     
    435423       
    436424        jd->flags |= JFLAG_STARTTLS_DONE;
    437 
    438         /* If the user specified a server for the account, use this server as the
    439          * hostname in the certificate verification. Else we use the domain from
    440          * the username. */
    441         if( ic->acc->server && *ic->acc->server )
    442                 tlsname = ic->acc->server;
    443         else
    444                 tlsname = jd->server;
    445        
    446         jd->ssl = ssl_starttls( jd->fd, tlsname, set_getbool( &ic->acc->set, "tls_verify" ),
    447                                 jabber_connected_ssl, ic );
     425        jd->ssl = ssl_starttls( jd->fd, jabber_connected_ssl, ic );
    448426       
    449427        return XT_HANDLED;
Note: See TracChangeset for help on using the changeset viewer.