diff options
author | Saturneric <[email protected]> | 2021-12-02 22:44:09 +0000 |
---|---|---|
committer | Saturneric <[email protected]> | 2021-12-04 19:28:28 +0000 |
commit | ea7c0113486f336f3fe14435e1ce5eb55ad4eca9 (patch) | |
tree | 8f1c5c61be4d55df5e7efad79e16f9c0212510db /src/gpg/function/GpgKeyOpera.cpp | |
parent | Fixed (diff) | |
download | GpgFrontend-ea7c0113486f336f3fe14435e1ce5eb55ad4eca9.tar.gz GpgFrontend-ea7c0113486f336f3fe14435e1ce5eb55ad4eca9.zip |
Fixed
1. Ci Fixed for New Version.
2. Bugs fixed for cross-platform.
3. Bugs fixed for i18n.
Diffstat (limited to 'src/gpg/function/GpgKeyOpera.cpp')
-rw-r--r-- | src/gpg/function/GpgKeyOpera.cpp | 67 |
1 files changed, 37 insertions, 30 deletions
diff --git a/src/gpg/function/GpgKeyOpera.cpp b/src/gpg/function/GpgKeyOpera.cpp index a7371904..c60f9157 100644 --- a/src/gpg/function/GpgKeyOpera.cpp +++ b/src/gpg/function/GpgKeyOpera.cpp @@ -24,7 +24,7 @@ #include "gpg/function/GpgKeyOpera.h" -#include <boost/asio/read_until.hpp> +#include <boost/asio.hpp> #include <boost/date_time/posix_time/conversion.hpp> #include <boost/process/async_pipe.hpp> #include <memory> @@ -99,38 +99,45 @@ void GpgFrontend::GpgKeyOpera::GenerateRevokeCert( using boost::asio::async_write; using boost::process::async_pipe; +#ifndef WINDOWS GpgCommandExecutor::GetInstance().Execute( args, [](async_pipe& in, async_pipe& out) -> void { - boost::asio::streambuf buff; - boost::asio::read_until(in, buff, '\n'); - - std::istream is(&buff); - - while (!is.eof()) { - std::string line; - is >> line; - LOG(INFO) << "line" << line; - boost::algorithm::trim(line); - if (line == std::string("[GNUPG:] GET_BOOL gen_revoke.okay")) { - - } else if (line == - std::string( - "[GNUPG:] GET_LINE ask_revocation_reason.code")) { - - } else if (line == - std::string( - "[GNUPG:] GET_LINE ask_revocation_reason.text")) { - - } else if (line == - std::string("[GNUPG:] GET_BOOL openfile.overwrite.okay")) { - - } else if (line == - std::string( - "[GNUPG:] GET_BOOL ask_revocation_reason.okay")) { - - } - } + // boost::asio::streambuf buff; + // boost::asio::read_until(in, buff, '\n'); + // + // std::istream is(&buff); + // + // while (!is.eof()) { + // std::string line; + // is >> line; + // LOG(INFO) << "line" << line; + // boost::algorithm::trim(line); + // if (line == std::string("[GNUPG:] GET_BOOL + // gen_revoke.okay")) { + // + // } else if (line == + // std::string( + // "[GNUPG:] GET_LINE + // ask_revocation_reason.code")) { + // + // } else if (line == + // std::string( + // "[GNUPG:] GET_LINE + // ask_revocation_reason.text")) { + // + // } else if (line == + // std::string("[GNUPG:] GET_BOOL + // openfile.overwrite.okay")) { + // + // } else if (line == + // std::string( + // "[GNUPG:] GET_BOOL + // ask_revocation_reason.okay")) { + // + // } + // } }); +#endif } /** |