Merge lp:~gue5t/midori/extension-tests into lp:midori
Status: | Merged |
---|---|
Approved by: | Paweł Forysiuk |
Approved revision: | 7094 |
Merged at revision: | 7099 |
Proposed branch: | lp:~gue5t/midori/extension-tests |
Merge into: | lp:midori |
Diff against target: |
173 lines (+48/-17) 2 files modified
midori/midori-extension.c (+2/-2) tests/extensions.c (+46/-15) |
To merge this branch: | bzr merge lp:~gue5t/midori/extension-tests |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Paweł Forysiuk | Approve | ||
Review via email: mp+283894@code.launchpad.net |
Commit message
Fix memory leaks and logic errors in extension loading and tests
Description of the change
In tests/extensions.c, there are lots of leaks which are fixed with the appropriate unref calls. extension_load is changed to return the extension it loads, so it can be freed. In addition, extension_load is changed to only register the tests when told to do so, because extension_load is called twice to exercise loading an extension multiple times--but GLib does not allow registering the same test twice. This is a correctness fix, and without it running "./tests/extensions -e ./extensions/
tests/extension.c also had a few misleading variable names which have been fixed.
In midori/