diff options
author | lloyd <[email protected]> | 2009-11-17 05:44:33 +0000 |
---|---|---|
committer | lloyd <[email protected]> | 2009-11-17 05:44:33 +0000 |
commit | c12e0e4f45497f8ecb628ba7d753f87aa8db0813 (patch) | |
tree | 5f2d3c4efd7efe0ac99366a84ebd50a062e15503 /doc/examples/gtk/gtk_ui.cpp | |
parent | 435965ac3b199d31b799ebefc012d928bc415621 (diff) | |
parent | 0d27bc0f8763cb6dd6307dbab7713058dee18b2c (diff) |
propagate from branch 'net.randombit.botan' (head cfb19182987fc95b2a8885584a38edb10b4709b3)
to branch 'net.randombit.botan.c++0x' (head 1570877c463fed4b632bc49a5b5ee27c57de2cb5)
Diffstat (limited to 'doc/examples/gtk/gtk_ui.cpp')
-rw-r--r-- | doc/examples/gtk/gtk_ui.cpp | 25 |
1 files changed, 13 insertions, 12 deletions
diff --git a/doc/examples/gtk/gtk_ui.cpp b/doc/examples/gtk/gtk_ui.cpp index 515fbc519..d4e9cd238 100644 --- a/doc/examples/gtk/gtk_ui.cpp +++ b/doc/examples/gtk/gtk_ui.cpp @@ -1,22 +1,23 @@ -/************************************************* -* GTK+ User Interface Source File * -*************************************************/ +/* +* GTK+ User Interface Source File +*/ #include "gtk_ui.h" +#include <cstring> -/************************************************* +/* * GTK+ Callback * -*************************************************/ +*/ void GTK_UI::callback(GtkWidget* entry, gpointer passphrase_ptr) { const gchar *entry_text = gtk_entry_get_text(GTK_ENTRY(entry)); char* passphrase = (char*)passphrase_ptr; - strcpy(passphrase, entry_text); + std::strcpy(passphrase, entry_text); } -/************************************************* -* Get a passphrase from the user * -*************************************************/ +/* +* Get a passphrase from the user +*/ std::string GTK_UI::get_passphrase(const std::string& what, const std::string& source, UI_Result& result) const @@ -26,9 +27,9 @@ std::string GTK_UI::get_passphrase(const std::string& what, return get_passphrase(msg, result); } -/************************************************* -* Get a passphrase from the user * -*************************************************/ +/* +* Get a passphrase from the user +*/ std::string GTK_UI::get_passphrase(const std::string& label_text, UI_Result& result) const { |