diff options
author | Michele Calgaro <[email protected]> | 2014-06-05 18:12:21 +0900 |
---|---|---|
committer | Michele Calgaro <[email protected]> | 2014-06-05 18:12:21 +0900 |
commit | 1eaefc42f9aeae973600e1c9b0b4bea7f4e48bdd (patch) | |
tree | 3905d183284401630e6392ad15a60a1da8f5cac4 | |
parent | 73fe57b2d3309e0c2aff8310a87929bd8cf6a334 (diff) | |
download | kshowmail-1eaefc42f9aeae973600e1c9b0b4bea7f4e48bdd.tar.gz kshowmail-1eaefc42f9aeae973600e1c9b0b4bea7f4e48bdd.zip |
Fixed "comparison with string literal results" warnings.
This resolves bug 1649.
-rw-r--r-- | kshowmail/kcmconfigs/accountsetupdialog.cpp | 2 | ||||
-rw-r--r-- | kshowmail/kcmconfigs/configlog.cpp | 12 | ||||
-rw-r--r-- | kshowmail/serverdialog.cpp | 2 |
3 files changed, 8 insertions, 8 deletions
diff --git a/kshowmail/kcmconfigs/accountsetupdialog.cpp b/kshowmail/kcmconfigs/accountsetupdialog.cpp index 19cfe0d..be1ce1a 100644 --- a/kshowmail/kcmconfigs/accountsetupdialog.cpp +++ b/kshowmail/kcmconfigs/accountsetupdialog.cpp @@ -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(); diff --git a/kshowmail/kcmconfigs/configlog.cpp b/kshowmail/kcmconfigs/configlog.cpp index 673a6ed..4f28464 100644 --- a/kshowmail/kcmconfigs/configlog.cpp +++ b/kshowmail/kcmconfigs/configlog.cpp @@ -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 ); diff --git a/kshowmail/serverdialog.cpp b/kshowmail/serverdialog.cpp index 4c051ad..17b6496 100644 --- a/kshowmail/serverdialog.cpp +++ b/kshowmail/serverdialog.cpp @@ -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(); |