diff options
author | Michele Calgaro <michele.calgaro@yahoo.it> | 2018-11-28 00:04:05 +0900 |
---|---|---|
committer | Michele Calgaro <michele.calgaro@yahoo.it> | 2018-11-28 00:04:05 +0900 |
commit | 6ae10fc66ed3c35e98e49bac8bf6670f0a9e2d6b (patch) | |
tree | 154aa555033fe887b9b56d8a559000c89b166f1e /kdesktop | |
parent | 3c2da5f0e188e1f1152da840bdf8d94ceb509671 (diff) | |
download | tdebase-6ae10fc66ed3c35e98e49bac8bf6670f0a9e2d6b.tar.gz tdebase-6ae10fc66ed3c35e98e49bac8bf6670f0a9e2d6b.zip |
Adapted to new KPasswordEdit::password() signature. This relates to bug 2961.
Signed-off-by: Michele Calgaro <michele.calgaro@yahoo.it>
Diffstat (limited to 'kdesktop')
-rw-r--r-- | kdesktop/lock/lockprocess.cc | 7 | ||||
-rw-r--r-- | kdesktop/lock/querydlg.cc | 2 | ||||
-rw-r--r-- | kdesktop/lock/querydlg.h | 2 | ||||
-rw-r--r-- | kdesktop/minicli.cpp | 4 |
4 files changed, 8 insertions, 7 deletions
diff --git a/kdesktop/lock/lockprocess.cc b/kdesktop/lock/lockprocess.cc index d7a63f14d..b34c5b494 100644 --- a/kdesktop/lock/lockprocess.cc +++ b/kdesktop/lock/lockprocess.cc @@ -2719,7 +2719,7 @@ void LockProcess::slotMouseActivity(XEvent *event) void LockProcess::processInputPipeCommand(TQString inputcommand) { TQCString command(inputcommand.ascii()); TQString to_display; - const char * pin_entry; + TQString pin_entry; if (command[0] == 'C') { while (mDialogControlLock == true) usleep(100000); @@ -2807,7 +2807,8 @@ void LockProcess::processInputPipeCommand(TQString inputcommand) { pin_entry = qryDlg.getEntry(); mInfoMessageDisplayed=false; if (mPipeOpen_out == true) { - if (write(mPipe_fd_out, pin_entry, strlen(pin_entry)+1) == -1) { + TQCString pin_entry_utf8 = pin_entry.utf8(); // utf8 length may differ from TQString length + if (write(mPipe_fd_out, pin_entry_utf8.data(), pin_entry_utf8.length()+1) == -1) { // Error handler to shut up gcc warnings } if (write(mPipe_fd_out, "\n\r", 3) == -1) { @@ -2896,7 +2897,7 @@ void LockProcess::signalPassDlgToAttemptCardAbort() { void LockProcess::cryptographicCardPinRequested(TQString prompt, TDECryptographicCardDevice* cdevice) { TQCString password; - const char * pin_entry; + TQString pin_entry; QueryDlg qryDlg(this); qryDlg.updateLabel(prompt); diff --git a/kdesktop/lock/querydlg.cc b/kdesktop/lock/querydlg.cc index 004bbc458..1fc5d260c 100644 --- a/kdesktop/lock/querydlg.cc +++ b/kdesktop/lock/querydlg.cc @@ -133,7 +133,7 @@ void QueryDlg::slotOK() close(); } -const char * QueryDlg::getEntry() +TQString QueryDlg::getEntry() { return pin_box->password(); } diff --git a/kdesktop/lock/querydlg.h b/kdesktop/lock/querydlg.h index 71f73f9ab..d5c4f7f33 100644 --- a/kdesktop/lock/querydlg.h +++ b/kdesktop/lock/querydlg.h @@ -38,7 +38,7 @@ class QueryDlg : public TQDialog void updateLabel( TQString &txt ); void setUnlockIcon(); void setWarningIcon(); - const char * getEntry(); + TQString getEntry(); private slots: void slotOK(); diff --git a/kdesktop/minicli.cpp b/kdesktop/minicli.cpp index afc28f3b0..9fb4a283c 100644 --- a/kdesktop/minicli.cpp +++ b/kdesktop/minicli.cpp @@ -483,7 +483,7 @@ int Minicli::runCommand() proc_checkpwd.setScheduler(m_iScheduler); } - if (proc_checkpwd.checkInstall(m_dlg->lePassword->password()) != 0) + if (proc_checkpwd.checkInstall(m_dlg->lePassword->password().utf8()) != 0) { KMessageBox::sorry(this, i18n("Incorrect password; please try again.")); return 1; @@ -534,7 +534,7 @@ int Minicli::runCommand() sigprocmask(SIG_BLOCK, &sset, 0L); proc.setTerminal(true); proc.setErase(true); - _exit(proc.exec(m_dlg->lePassword->password())); + _exit(proc.exec(m_dlg->lePassword->password().utf8())); return 0; } else |