author | llornkcor <llornkcor> | 2005-02-06 02:49:25 (UTC) |
---|---|---|
committer | llornkcor <llornkcor> | 2005-02-06 02:49:25 (UTC) |
commit | 6764eece4d63724d55252b2cbfa04e8f2fb5787d (patch) (side-by-side diff) | |
tree | 914f5d32d4c353f27e659d246ae0588a18c5d7a4 | |
parent | c3892e6c1a4ca15383a7da48f6d72b1d7d26f43d (diff) | |
download | opie-6764eece4d63724d55252b2cbfa04e8f2fb5787d.zip opie-6764eece4d63724d55252b2cbfa04e8f2fb5787d.tar.gz opie-6764eece4d63724d55252b2cbfa04e8f2fb5787d.tar.bz2 |
too long
-rw-r--r-- | core/apps/embeddedkonsole/konsole.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/core/apps/embeddedkonsole/konsole.cpp b/core/apps/embeddedkonsole/konsole.cpp index 8b4202d..de00494 100644 --- a/core/apps/embeddedkonsole/konsole.cpp +++ b/core/apps/embeddedkonsole/konsole.cpp @@ -105,131 +105,131 @@ public: return(size); } } }; class EKNumTabWidget : public QTabWidget { public: EKNumTabWidget(QWidget* parent) : QTabWidget(parent) { setTabBar(new EKNumTabBar(parent,"EKTabBar")); setSizePolicy( QSizePolicy( QSizePolicy::Expanding, QSizePolicy::Expanding ) ); } EKNumTabBar *getTabBar() const { return ((EKNumTabBar*)tabBar()); } void addTab(QWidget* w) { QTab* t = new QTab(QString::number(tabBar()->count()+1)); QTabWidget::addTab(w,t); } void removeTab(QWidget* w) { removePage(w); ((EKNumTabBar*)tabBar())->numberTabs(); } }; // This could be configurable or dynamicly generated from the bash history // file of the user static const char *commonCmds[] = { "ls ", // I left this here, cause it looks better than the first alpha "cardctl eject", "cat ", "cd ", "chmod ", "clear", "cp ", "dc ", "df ", "dmesg", "echo ", "env", "find ", "free", "grep ", "ifconfig ", "ipkg ", "mkdir ", "mv ", "nc localhost 7776", "nc localhost 7777", "netstat ", "nslookup ", "ping ", "ps aux", "pwd ", - "qcop QPE/System 'linkChanged(QString)' ''", - "qcop QPE/System 'restart()'", - "qcop QPE/System 'quit()'", +// "qcop QPE/System 'linkChanged(QString)' ''", +// "qcop QPE/System 'restart()'", +// "qcop QPE/System 'quit()'", "rm ", "rmdir ", "route ", "set ", "traceroute", /* "gzip", "gunzip", "chgrp", "chown", "date", "dd", "df", "dmesg", "fuser", "hostname", "kill", "killall", "ln", "ping", "mount", "more", "sort", "touch", "umount", "mknod", "netstat", */ "exit", NULL }; static void konsoleInit(const char** shell) { if(setuid(getuid()) !=0) odebug << "setuid failed" << oendl; if(setgid(getgid()) != 0) odebug << "setgid failed" << oendl; // drop privileges // QPEApplication::grabKeyboard(); // for CTRL and ALT odebug << "keyboard grabbed" << oendl; #ifdef FAKE_CTRL_AND_ALT odebug << "Fake Ctrl and Alt defined" << oendl; QPEApplication::grabKeyboard(); // for CTRL and ALT #endif *shell = getenv("SHELL"); owarn << "SHell initially is " << *shell << "" << oendl; if (shell == NULL || *shell == '\0') { struct passwd *ent = 0; uid_t me = getuid(); *shell = "/bin/sh"; while ( (ent = getpwent()) != 0 ) { if (ent->pw_uid == me) { if (ent->pw_shell != "") *shell = ent->pw_shell; break; } } endpwent(); |