Fix memory leak; unref type info we created, not field info

We expect callers to own the FieldInfo, we should not unref it.  However
we should unref the type info we accessed.

svn path=/trunk/; revision=981
This commit is contained in:
Colin Walters 2008-12-01 17:05:37 +00:00
parent 74e22b307c
commit 9c62e9fc6e

View File

@ -197,7 +197,7 @@ g_field_info_get_field (GIFieldInfo *field_info,
}
}
g_base_info_unref ((GIBaseInfo *)field_info);
g_base_info_unref ((GIBaseInfo *)type_info);
return result;
}
@ -389,7 +389,7 @@ g_field_info_set_field (GIFieldInfo *field_info,
}
}
g_base_info_unref ((GIBaseInfo *)field_info);
g_base_info_unref ((GIBaseInfo *)type_info);
return result;
}