diff options
author | jstebbins <[email protected]> | 2014-02-21 00:23:37 +0000 |
---|---|---|
committer | jstebbins <[email protected]> | 2014-02-21 00:23:37 +0000 |
commit | d206a74fb8500b64310b75be8db08ec9e0a972f5 (patch) | |
tree | 15941705a5f17d83f29e2b28fc1d548fe5aab9e3 /gtk/src/values.c | |
parent | cc82c19b2f52a7527615ccbae34154e0085b6708 (diff) |
LinGui: fix range update issues and plug memory leaks
Updating the range of GtkScale and GtkSpinButtons causes the current
value to update inappropriately under some conditions. So update
the range and value concurrently.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@6051 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'gtk/src/values.c')
-rw-r--r-- | gtk/src/values.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/gtk/src/values.c b/gtk/src/values.c index 85886e17e..3b5c5df38 100644 --- a/gtk/src/values.c +++ b/gtk/src/values.c @@ -713,7 +713,11 @@ ghb_array_copy(GValue *arr1, GValue *arr2, gint count) // empty the first array if it is not already empty len = ghb_array_len(arr1); for (ii = 0; ii < len; ii++) + { + GValue *old = ghb_array_get_nth(arr1, 0); ghb_array_remove(arr1, 0); + ghb_value_free(old); + } len = ghb_array_len(arr2); count = MIN(count, len); |