notify::diff() keeps line breaks in the diff buffer before calling
patch::diffstat().
patch::diffstat() adds another line break when feeding diffstat input.
This combination results in an extra empty line in diffstat input, leading to
erroneous diffstat output.
To reproduce: a one line diff in a file is most of the time ignored (diffstat
outputs '0 file changed'), the stats are otherwise inaccurate.
The proposed patch in attachment the line breaks in notify::diff() and loops
through the diff lines to print them.
Cheers,
Divy
|