in form_dealloc, only hide the form if it's visible
diff --git a/Modules/flmodule.c b/Modules/flmodule.c
index f51586a..2d26533 100644
--- a/Modules/flmodule.c
+++ b/Modules/flmodule.c
@@ -1816,7 +1816,8 @@
 	formobject *f;
 {
 	releaseobjects(f->ob_form);
-	fl_hide_form(f->ob_form);
+	if (f->ob_form->visible)
+		fl_hide_form(f->ob_form);
 	fl_free_form(f->ob_form);
 	DEL(f);
 }