Merge lp:~gz/bzr/avoid_diff_delta_empty_malloc_856731 into lp:bzr/2.4
Proposed by
Martin Packman
Status: | Merged |
---|---|
Approved by: | Vincent Ladeuil |
Approved revision: | no longer in the source branch. |
Merged at revision: | 6049 |
Proposed branch: | lp:~gz/bzr/avoid_diff_delta_empty_malloc_856731 |
Merge into: | lp:bzr/2.4 |
Diff against target: |
29 lines (+9/-0) 2 files modified
bzrlib/diff-delta.c (+5/-0) doc/en/release-notes/bzr-2.4.txt (+4/-0) |
To merge this branch: | bzr merge lp:~gz/bzr/avoid_diff_delta_empty_malloc_856731 |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Martin Pool | Approve | ||
John A Meinel | Approve | ||
Review via email: mp+77737@code.launchpad.net |
Commit message
Bug #856731, avoid calling malloc(0) for platforms that return NULL (such as AIX)
Description of the change
Very simple fix from John to avoid quirks with doing malloc(0) on some platforms.
I tested faking out that call point to behave in the funky manner reported, and running `bzr selftest -s bt.test_
The bug was reported against 2.2 but I think 2.4 is far enough to go back, even with a change this minimal.
To post a comment you must log in.
I'm fine with this change, but it would be nice to actually run it on AIX to make sure it works as expected.
We should also audit to see if there are any other malloc(0) cases.