Browse Source

Bugfix: Free input memory after prioritising pools in TUI

Luke Dashjr 13 years ago
parent
commit
344e3cfded
1 changed files with 4 additions and 1 deletions
  1. 4 1
      miner.c

+ 4 - 1
miner.c

@@ -4421,7 +4421,10 @@ retry:
 		opt_fail_only ^= true;
 		goto updated;
         } else if (!strncasecmp(&input, "p", 1)) {
-        	switch (prioritize_pools(curses_input("Enter new pool priority (comma separated list)"), &i)) {
+			char *prilist = curses_input("Enter new pool priority (comma separated list)");
+			int res = prioritize_pools(prilist, &i);
+			free(prilist);
+			switch (res) {
         		case MSG_NOPOOL:
         			wlogprint("No pools\n");
         			goto retry;