From 122f09af5d1786d1c0b6ae6175e5eb91170dea7f Mon Sep 17 00:00:00 2001 From: Chris Young Date: Wed, 15 Aug 2018 17:39:36 +0100 Subject: Close login window if NetSurf quits --- frontends/amiga/login.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'frontends/amiga') diff --git a/frontends/amiga/login.c b/frontends/amiga/login.c index 6735f9350..9cdf79504 100755 --- a/frontends/amiga/login.c +++ b/frontends/amiga/login.c @@ -63,11 +63,11 @@ struct gui_login_window { }; static BOOL ami_401login_event(void *w); +static void ami_401login_close(void *w) static const struct ami_win_event_table ami_login_table = { ami_401login_event, - NULL, /* we don't explicitly close the login window at all. - @todo check if this prevents us from quitting NetSurf */ + ami_401login_close, }; nserror gui_401login_open(nsurl *url, const char *realm, @@ -175,8 +175,10 @@ nserror gui_401login_open(nsurl *url, const char *realm, return NSERROR_OK; } -static void ami_401login_close(struct gui_login_window *lw) +static void ami_401login_close(void *w) { + struct gui_login_window *lw = (struct gui_login_window *)w; + /* If continuation exists, then forbid refetch */ if (lw->cb != NULL) lw->cb(NULL, NULL, lw->cbpw); -- cgit v1.2.3