From: Ralph Corderoy Date: Tue, 18 Oct 2016 13:52:25 +0000 (+0100) Subject: Replace getcpy() with mh_xstrdup() where the string isn't NULL. X-Git-Url: https://diplodocus.org/git/nmh/commitdiff_plain/35caf2388aecd13abc4fa67962c01186017af88d Replace getcpy() with mh_xstrdup() where the string isn't NULL. --- diff --git a/uip/mhlogin.c b/uip/mhlogin.c index 46a5a161..d6dd0afd 100644 --- a/uip/mhlogin.c +++ b/uip/mhlogin.c @@ -11,6 +11,7 @@ #include #include +#include #include #define MHLOGIN_SWITCHES \ @@ -71,7 +72,7 @@ do_login(const char *svc, const char *user, const char *browser, int snoop) mh_oauth_log_to(stderr, ctx); } - fn = getcpy(mh_oauth_cred_fn(svc)); + fn = mh_xstrdup(mh_oauth_cred_fn(svc)); if ((url = mh_oauth_get_authorize_url(ctx)) == NULL) { adios(NULL, mh_oauth_get_err_string(ctx));