about summary refs log tree commit diff stats
path: root/src
diff options
context:
space:
mode:
authorJames Booth <boothj5@gmail.com>2015-01-14 21:52:13 +0000
committerJames Booth <boothj5@gmail.com>2015-01-14 21:52:13 +0000
commit5cf7ef0b4f214884136b15ecad7ce860659f03b4 (patch)
treef35051ff1620dacf583778e820410d431260001f /src
parentb5d4a52dfa6386461af55c93b934fc2af5acc6ea (diff)
downloadprofani-tty-5cf7ef0b4f214884136b15ecad7ce860659f03b4.tar.gz
Don't free default account name until it has been lowercased
Diffstat (limited to 'src')
-rw-r--r--src/command/commands.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/command/commands.c b/src/command/commands.c
index 9fd6eed4..98fe72e4 100644
--- a/src/command/commands.c
+++ b/src/command/commands.c
@@ -125,11 +125,11 @@ cmd_connect(gchar **args, struct cmd_help_t help)
                 return TRUE;
             }
         }
-        g_free(def);
-        def = NULL;
 
         char *lower = g_utf8_strdown(user, -1);
         char *jid;
+        g_free(def);
+        def = NULL;
 
         ProfAccount *account = accounts_get_account(lower);
         if (account != NULL) {