]> asedeno.scripts.mit.edu Git - PuTTY.git/blobdiff - window.c
First phase of porting. pterm now compiles and runs under Linux+gtk.
[PuTTY.git] / window.c
index 9ea6c018a0409e76bb006a220c13c1b57748d42d..59757d91fdf10c1d3a1765f7c7486bd71911f34f 100644 (file)
--- a/window.c
+++ b/window.c
@@ -4201,6 +4201,22 @@ void fatalbox(char *fmt, ...)
     cleanup_exit(1);
 }
 
+/*
+ * Print a modal (Really Bad) message box and perform a fatal exit.
+ */
+void modalfatalbox(char *fmt, ...)
+{
+    va_list ap;
+    char stuff[200];
+
+    va_start(ap, fmt);
+    vsprintf(stuff, fmt, ap);
+    va_end(ap);
+    MessageBox(hwnd, stuff, "PuTTY Fatal Error",
+              MB_SYSTEMMODAL | MB_ICONERROR | MB_OK);
+    cleanup_exit(1);
+}
+
 /*
  * Manage window caption / taskbar flashing, if enabled.
  * 0 = stop, 1 = maintain, 2 = start