Bug 90419 - PATCH/FIXME: remove global variable keytab_serial
Summary: PATCH/FIXME: remove global variable keytab_serial
Status: RESOLVED NOT A BUG
Alias: None
Product: konsole
Classification: Applications
Component: general (show other bugs)
Version: unspecified
Platform: Compiled Sources Linux
: NOR wishlist
Target Milestone: ---
Assignee: Konsole Developer
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-09-28 20:19 UTC by Kurt Hindenburg
Modified: 2004-12-17 06:49 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Kurt Hindenburg 2004-09-28 20:19:34 UTC
Version:            (using KDE Devel)
Installed from:    Compiled sources
OS:                Linux

Any reason not to do this?

===================================================================
RCS file: /home/kde/kdebase/konsole/konsole/keytrans.cpp,v
retrieving revision 1.48
diff -u -p -r1.48 keytrans.cpp
--- keytrans.cpp        22 Sep 2004 20:02:16 -0000      1.48
+++ keytrans.cpp        28 Sep 2004 18:17:07 -0000
@@ -636,8 +636,6 @@ KeyTransSymbols::KeyTransSymbols()

 // Global material -----------------------------------------------------------

-static int keytab_serial = 0; //FIXME: remove,localize
-
 static QIntDict<KeyTrans> * numb2keymap = 0L;

 KeyTrans* KeyTrans::find(int numb)
@@ -665,7 +663,7 @@ int KeyTrans::count()

 void KeyTrans::addKeyTrans()
 {
-  m_numb = keytab_serial ++;
+  m_numb = numb2keymap->count(); // or m_numb=count();
   numb2keymap->insert(m_numb,this);
 }
Comment 1 Kurt Hindenburg 2004-12-17 06:49:50 UTC
A rather stupid bug for such a simple thing.