summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFrançois Andriot <[email protected]>2015-03-24 00:29:54 +0100
committerSlávek Banko <[email protected]>2015-03-24 00:30:44 +0100
commit5ae4a0b3a69d678ca1d8b26a2c0ae648fb491140 (patch)
tree1e93a30aac76a04b41339ffc709af3f7d8edf13d
parentf9587c343022a393f4e174db53b5b930ce438a0c (diff)
downloadbibletime-5ae4a0b3a69d678ca1d8b26a2c0ae648fb491140.tar.gz
bibletime-5ae4a0b3a69d678ca1d8b26a2c0ae648fb491140.zip
Use strcmp instead of string comparison
Signed-off-by: François Andriot <[email protected]> (cherry picked from commit a18630c354f72892e293c1ef483d86c978bcb5f3)
-rw-r--r--bibletime/backend/cswordbackend.cpp2
-rw-r--r--bibletime/frontend/cdragdropmgr.cpp2
2 files changed, 2 insertions, 2 deletions
diff --git a/bibletime/backend/cswordbackend.cpp b/bibletime/backend/cswordbackend.cpp
index 1c218b3..ba7f4d9 100644
--- a/bibletime/backend/cswordbackend.cpp
+++ b/bibletime/backend/cswordbackend.cpp
@@ -251,7 +251,7 @@ const bool CSwordBackend::shutdownModules() {
/** Returns true if the given option is enabled. */
const bool CSwordBackend::isOptionEnabled( const CSwordModuleInfo::FilterTypes type) {
- return (getGlobalOption( optionName(type).latin1() ) == "On");
+ return (strcmp(getGlobalOption( optionName(type).latin1() ), "On") == 0);
}
/** Sets the given options enabled or disabled depending on the second parameter. */
diff --git a/bibletime/frontend/cdragdropmgr.cpp b/bibletime/frontend/cdragdropmgr.cpp
index 52d012f..428644f 100644
--- a/bibletime/frontend/cdragdropmgr.cpp
+++ b/bibletime/frontend/cdragdropmgr.cpp
@@ -36,7 +36,7 @@ bool CDragDropMgr::BTDrag::canDecode( const TQMimeSource * mime ) {
};
bool CDragDropMgr::BTDrag::provides( const char* type ) const {
- return (type == "BibleTime/DND"); //return only true if the type is BibleTime/DND
+ return (strcmp(type, "BibleTime/DND") == 0); //return only true if the type is BibleTime/DND
};
const char* CDragDropMgr::BTDrag::format( int i ) const {