On Wed, Sep 13, 2017 at 02:20:35PM -0700, Jonathan Nieder wrote:
> > --- a/notes-merge.c
> > +++ b/notes-merge.c
> > @@ -302,7 +302,7 @@ static void write_buf_to_worktree(const struct
> > object_id *obj,
> > fd = xopen(path, O_WRONLY | O_EXCL | O_CREAT, 0666);
> >
> > while (size > 0) {
> > - long ret = write_in_full(fd, buf, size);
> > + ssize_t ret = write_in_full(fd, buf, size);
> > if (ret < 0) {
> > /* Ignore epipe */
> > if (errno == EPIPE)
> > break;
> > die_errno("notes-merge");
> > } else if (!ret) {
> > die("notes-merge: disk full?");
> > }
>
> These three lines are dead code. How about the following, e.g. for
> squashing in?
Thanks, I didn't notice that.
I'd actually prefer it as a separate patch, since it needs explained
separately.
-Peff