summaryrefslogtreecommitdiff
path: root/client/gtk.c
diff options
context:
space:
mode:
authorSamuel Lidén Borell <samuel@kodafritt.se>2014-08-19 23:38:15 +0200
committerSamuel Lidén Borell <samuel@kodafritt.se>2014-08-19 23:38:15 +0200
commitd6ec1e4d28c794a1d3fa92956a313d6dca46fead (patch)
treeaba12c68c9bb4931e714f24939c1d125c3dfc660 /client/gtk.c
parent657bd7b4058125dcc02375cd92b14b73d2d63fa3 (diff)
downloadfribid-d6ec1e4d28c794a1d3fa92956a313d6dca46fead.tar.gz
fribid-d6ec1e4d28c794a1d3fa92956a313d6dca46fead.tar.bz2
fribid-d6ec1e4d28c794a1d3fa92956a313d6dca46fead.zip
Show an error message when certificate retreival fails
Diffstat (limited to 'client/gtk.c')
-rw-r--r--client/gtk.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/client/gtk.c b/client/gtk.c
index 5f670a2..ad5057b 100644
--- a/client/gtk.c
+++ b/client/gtk.c
@@ -64,6 +64,15 @@ static const char *getErrorString(TokenError errorCode) {
case TokenError_SignatureFailure:
s = translatable("Failed to create signature");
break;
+ case TokenError_HostnameMismatch:
+ s = translatable("Domain name mismatch");
+ break;
+ case TokenError_NoCertsMatched:
+ s = translatable("The certificates didn't match");
+ break;
+ case TokenError_FailedToStoreCerts:
+ s = translatable("Failed to store received certificates");
+ break;
/* File errors */
case TokenError_FileNotReadable:
s = translatable("The file could not be read");
@@ -192,6 +201,9 @@ static void showMessage(GtkMessageType type, const char *text) {
GtkWidget *dialog = gtk_message_dialog_new(
GTK_WINDOW(activeDialog), GTK_DIALOG_DESTROY_WITH_PARENT,
type, GTK_BUTTONS_CLOSE, "%s", text);
+ if (!activeDialog) {
+ gtk_window_set_title(GTK_WINDOW(dialog), "FriBID");
+ }
gtk_dialog_run(GTK_DIALOG(dialog));
gtk_widget_destroy(dialog);
}