X-Git-Url: https://git.distorted.org.uk/~mdw/disorder/blobdiff_plain/93ca1bcfefc511c5d3ca0fd71d01b24614d0d7fd..6961095b797229842e1465ff3670625d11e95167:/disobedience/login.c diff --git a/disobedience/login.c b/disobedience/login.c index a02c1c6..0c6e7d7 100644 --- a/disobedience/login.c +++ b/disobedience/login.c @@ -120,11 +120,13 @@ static void set_service(struct config *c, const char *s) { } static void set_username(struct config *c, const char *s) { - c->username = s; + xfree(c->username); + c->username = xstrdup(s); } static void set_password(struct config *c, const char *s) { - c->password = s; + xfree(c->password); + c->password = xstrdup(s); } /** @brief Table used to generate the form */