Fixed "comparison with string literal results" warnings.

This resolves bug 1649.
pull/1/head
Michele Calgaro 11 years ago
parent 73fe57b2d3
commit 1eaefc42f9

@ -256,7 +256,7 @@ void AccountSetupDialog::slotOk( )
//will return an empty string. If the user has typed in a new password, KPasswordEdit::password()
//will return the correct password
TQString pass;
if( txtPassword->password() == "" || txtPassword->password() == TQString::null )
if( txtPassword->password() == TQString("") || txtPassword->password() == TQString::null )
pass = txtPassword->text();
else
pass = txtPassword->password();

@ -121,7 +121,7 @@ void ConfigLog::load()
else if( config->readEntry( CONFIG_ENTRY_LOG_REMOVE_DELETED_MAILS, DEFAULT_LOG_REMOVE_DELETED_MAILS ) == CONFIG_VALUE_LOG_REMOVE_MAILS_AFTER_DAYS )
grpDelMailsRemove->setButton( ID_BUTTON_REMOVE_AFTER_DAYS );
else
if( DEFAULT_LOG_REMOVE_DELETED_MAILS == CONFIG_VALUE_LOG_REMOVE_MAILS_AT_EXIT )
if (!strcmp(DEFAULT_LOG_REMOVE_DELETED_MAILS, CONFIG_VALUE_LOG_REMOVE_MAILS_AT_EXIT))
grpDelMailsRemove->setButton( ID_BUTTON_REMOVE_AT_EXIT );
else
grpDelMailsRemove->setButton( ID_BUTTON_REMOVE_AFTER_DAYS );
@ -131,7 +131,7 @@ void ConfigLog::load()
else if( config->readEntry( CONFIG_ENTRY_LOG_REMOVE_MOVED_MAILS, DEFAULT_LOG_REMOVE_MOVED_MAILS ) == CONFIG_VALUE_LOG_REMOVE_MAILS_AFTER_DAYS )
grpMovMailsRemove->setButton( ID_BUTTON_REMOVE_AFTER_DAYS );
else
if( DEFAULT_LOG_REMOVE_MOVED_MAILS == CONFIG_VALUE_LOG_REMOVE_MAILS_AT_EXIT )
if (!strcmp(DEFAULT_LOG_REMOVE_MOVED_MAILS, CONFIG_VALUE_LOG_REMOVE_MAILS_AT_EXIT))
grpMovMailsRemove->setButton( ID_BUTTON_REMOVE_AT_EXIT );
else
grpMovMailsRemove->setButton( ID_BUTTON_REMOVE_AFTER_DAYS );
@ -155,16 +155,16 @@ void ConfigLog::defaults()
else
chkLogMovedMails->setChecked( false );
if( DEFAULT_LOG_REMOVE_DELETED_MAILS == CONFIG_VALUE_LOG_REMOVE_MAILS_AT_EXIT )
if (!strcmp(DEFAULT_LOG_REMOVE_DELETED_MAILS, CONFIG_VALUE_LOG_REMOVE_MAILS_AT_EXIT))
grpDelMailsRemove->setButton( ID_BUTTON_REMOVE_AT_EXIT );
else if( DEFAULT_LOG_REMOVE_DELETED_MAILS == CONFIG_VALUE_LOG_REMOVE_MAILS_AFTER_DAYS )
else if (!strcmp(DEFAULT_LOG_REMOVE_DELETED_MAILS, CONFIG_VALUE_LOG_REMOVE_MAILS_AFTER_DAYS))
grpDelMailsRemove->setButton( ID_BUTTON_REMOVE_AFTER_DAYS );
else
grpDelMailsRemove->setButton( ID_BUTTON_REMOVE_AFTER_DAYS );
if( DEFAULT_LOG_REMOVE_MOVED_MAILS == CONFIG_VALUE_LOG_REMOVE_MAILS_AT_EXIT )
if (!strcmp(DEFAULT_LOG_REMOVE_MOVED_MAILS, CONFIG_VALUE_LOG_REMOVE_MAILS_AT_EXIT))
grpMovMailsRemove->setButton( ID_BUTTON_REMOVE_AT_EXIT );
else if( DEFAULT_LOG_REMOVE_MOVED_MAILS == CONFIG_VALUE_LOG_REMOVE_MAILS_AFTER_DAYS )
else if (!strcmp(DEFAULT_LOG_REMOVE_MOVED_MAILS, CONFIG_VALUE_LOG_REMOVE_MAILS_AFTER_DAYS))
grpMovMailsRemove->setButton( ID_BUTTON_REMOVE_AFTER_DAYS );
else
grpMovMailsRemove->setButton( ID_BUTTON_REMOVE_AFTER_DAYS );

@ -217,7 +217,7 @@ void ServerDialog::slotOk( )
//will return an empty string. If the user has typed in a new password, KPasswordEdit::password()
//will return the correct password
TQString pass;
if( txtPassword->password() == "" || txtPassword->password() == TQString::null )
if( txtPassword->password() == TQString("") || txtPassword->password() == TQString::null )
pass = txtPassword->text();
else
pass = txtPassword->password();

Loading…
Cancel
Save