summaryrefslogtreecommitdiffstats
path: root/konsole
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-08-15 21:36:27 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-08-15 21:36:27 +0000
commitd54ab5595153b3dc57560077ff3551ffd4406b30 (patch)
tree9c48320521bf9ec3cb310c4046289d5a28ec3213 /konsole
parent4b12a38f6e566f44f5549b4a85e3ae9e715e0d08 (diff)
downloadtdebase-d54ab5595153b3dc57560077ff3551ffd4406b30.tar.gz
tdebase-d54ab5595153b3dc57560077ff3551ffd4406b30.zip
Fix a number of issues in kdebase caused by C style casts
This includes Bug #492 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdebase@1247425 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'konsole')
-rw-r--r--konsole/konsole/keytrans.cpp2
-rw-r--r--konsole/konsole/main.cpp4
2 files changed, 3 insertions, 3 deletions
diff --git a/konsole/konsole/keytrans.cpp b/konsole/konsole/keytrans.cpp
index da197a69..b3aa76e9 100644
--- a/konsole/konsole/keytrans.cpp
+++ b/konsole/konsole/keytrans.cpp
@@ -143,7 +143,7 @@ bool KeyTrans::findEntry(int key, int bits, int* cmd, const char** txt, int* len
char *c;
char mask = '1' + BITS(0, bits&(1<<BITS_Shift)) + BITS(1, bits&(1<<BITS_Alt)) + BITS(2, bits&(1<<BITS_Control));
strcpy(buf, it.current()->txt.ascii());
- c = (char*)strchr(buf, '*');
+ c = strchr(buf, '*');
if (c) *c = mask;
*txt = buf;
}
diff --git a/konsole/konsole/main.cpp b/konsole/konsole/main.cpp
index 5b391a5e..d37a43be 100644
--- a/konsole/konsole/main.cpp
+++ b/konsole/konsole/main.cpp
@@ -111,7 +111,7 @@ const char *konsole_shell(TQStrList &args)
if (shell == NULL || *shell == '\0') shell = "/bin/sh";
if (login_shell)
{
- char* t = (char*)strrchr(shell,'/');
+ char* t = const_cast<char*>(strrchr(shell,'/'));
if (t) // see sh(1)
{
t = strdup(t);
@@ -451,7 +451,7 @@ extern "C" int KDE_EXPORT kdemain(int argc, char* argv[])
int c = 0, l = 0;
if ( !sz.isEmpty() )
{
- char *ls = (char*)strchr( sz.data(), 'x' );
+ char *ls = strchr( sz.data(), 'x' );
if ( ls != NULL )
{
*ls='\0';