Created
September 3, 2015 16:40
-
-
Save shadeslayer/c2e36223d2c90b96b1b9 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
QProcess *kcheckpass = new QProcess(); | |
kcheckpass->start("/usr/lib/x86_64-linux-gnu/libexec/kcheckpass"); | |
kcheckpass->waitForStarted(); | |
kDebug() << "Started"; | |
kcheckpass->waitForReadyRead(); | |
kDebug() << "Ready to read"; | |
kcheckpass->write(password.data()); | |
kcheckpass->waitForFinished(); | |
int ec = kcheckpass->exitCode(); | |
kDebug() << "MAGIC" << ec; | |
if (ec == 0) | |
return true; | |
else | |
return false; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment