mirror of
https://github.com/profanity-im/profanity.git
synced 2024-12-04 14:46:46 -05:00
Fixed GString freeing before use in otr.c
This commit is contained in:
parent
df760bed18
commit
443b240ce4
@ -130,9 +130,9 @@ otr_on_connect(ProfAccount *account)
|
|||||||
g_string_append(basedir, "/");
|
g_string_append(basedir, "/");
|
||||||
|
|
||||||
if (!mkdir_recursive(basedir->str)) {
|
if (!mkdir_recursive(basedir->str)) {
|
||||||
g_string_free(basedir, TRUE);
|
|
||||||
log_error("Could not create %s for account %s.", basedir->str, jid);
|
log_error("Could not create %s for account %s.", basedir->str, jid);
|
||||||
cons_show_error("Could not create %s for account %s.", basedir->str, jid);
|
cons_show_error("Could not create %s for account %s.", basedir->str, jid);
|
||||||
|
g_string_free(basedir, TRUE);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -211,9 +211,9 @@ otr_keygen(ProfAccount *account)
|
|||||||
g_string_append(basedir, "/");
|
g_string_append(basedir, "/");
|
||||||
|
|
||||||
if (!mkdir_recursive(basedir->str)) {
|
if (!mkdir_recursive(basedir->str)) {
|
||||||
g_string_free(basedir, TRUE);
|
|
||||||
log_error("Could not create %s for account %s.", basedir->str, jid);
|
log_error("Could not create %s for account %s.", basedir->str, jid);
|
||||||
cons_show_error("Could not create %s for account %s.", basedir->str, jid);
|
cons_show_error("Could not create %s for account %s.", basedir->str, jid);
|
||||||
|
g_string_free(basedir, TRUE);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user