Skip to content

Instantly share code, notes, and snippets.

@mlschroe
Created August 26, 2011 17:21
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mlschroe/1173901 to your computer and use it in GitHub Desktop.
Save mlschroe/1173901 to your computer and use it in GitHub Desktop.
--- nqp/src/6model/multi_dispatch.c.orig 2011-08-26 16:05:00.000000000 +0000
+++ nqp/src/6model/multi_dispatch.c 2011-08-26 17:21:15.000000000 +0000
@@ -222,6 +222,14 @@ static candidate_info** sort_candidates(
/* Free memory associated with the graph. */
for (i = 0; i < num_candidates; i++) {
+ candidate_info *info = graph[i]->info;
+ if (info) {
+ mem_sys_free(info);
+ if (info->types)
+ mem_sys_free(info->types);
+ if (info->definednesses)
+ mem_sys_free(info->definednesses);
+ }
mem_sys_free(graph[i]->edges);
mem_sys_free(graph[i]);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment