diff options
Diffstat (limited to 'frontends/atari/gui.c')
-rw-r--r-- | frontends/atari/gui.c | 39 |
1 files changed, 23 insertions, 16 deletions
diff --git a/frontends/atari/gui.c b/frontends/atari/gui.c index 6ee63b301..14e02e5f8 100644 --- a/frontends/atari/gui.c +++ b/frontends/atari/gui.c @@ -767,23 +767,30 @@ static void gui_set_clipboard(const char *buffer, size_t length, } static void gui_401login_open(nsurl *url, const char *realm, - nserror (*cb)(bool proceed, void *pw), void *cbpw) + const char *username, const char *password, + nserror (*cb)(const char *username, + const char *password, + void *pw), + void *cbpw) { - bool bres; - char * out = NULL; - bres = login_form_do( url, (char*)realm, &out); - if (bres) { - NSLOG(netsurf, INFO, "url: %s, realm: %s, auth: %s\n", - nsurl_access(url), realm, out); - urldb_set_auth_details(url, realm, out); - } - if (out != NULL) { - free( out ); - } - if (cb != NULL) { - cb(bres, cbpw); - } - + bool bres; + char * u_out = NULL; + char * p_out = NULL; + + bres = login_form_do(url, (char*)realm, &u_out, &p_out); + if (bres) { + NSLOG(netsurf, INFO, "url: %s, realm: %s, auth: %s\n", + nsurl_access(url), realm, out); + } + if (cb != NULL) { + cb(u_out, p_out, cbpw); + } + if (u_out != NULL) { + free(u_out); + } + if (p_out != NULL) { + free(p_out); + } } static nserror |