On Fri, 2016-10-07 at 17:52 +1100, Brian May wrote:
> > Ben Hutchings <[email protected]> writes:
> 
> > > It looks like this patch does three things
> > > 
> > > * It removes "assert(n > 0)".
> > > 
> > > * It removes the now unused n parameter from the
> > >   manager_invoke_notify_message() function.
> > > 
> > > * It removes the return(0) if n==0. This looks like the only relevant 
> > > part.
> > > 
> > > For the first two changes, it looks like the
> > > manager_invoke_notify_message() function and hence the assert was only
> > > introduced in systemd in the following commit, before tag v209. This was
> > > not in the wheezy version, so I don't think these parts are required.
> > 
> > [...]
> > 
> > Right.
> 
> 
> This means patch 4 is just the inverse of patch 3, so both become
> redundant.

Oh, I didn't realise that.  Let's drop those then.

[...]
> > 
> --- systemd-44/debian/patches/no_error_on_zero_len.patch      1970-01-01 
> 10:00:00.000000000 +1000
> +++ systemd-44/debian/patches/no_error_on_zero_len.patch      2016-10-06 
> 18:16:46.000000000 +1100
> @@ -0,0 +1,12 @@
> +--- a/src/manager.c
> ++++ b/src/manager.c
> +@@ -2030,9 +2030,6 @@
> +                 msghdr.msg_controllen = sizeof(control);
> + 
> +                 if ((n = recvmsg(m->notify_watch.fd, &msghdr, 
> MSG_DONTWAIT)) <= 0) {
> +-                        if (n >= 0)
> +-                                return -EIO;
> +-
> +                         if (errno == EAGAIN || errno == EINTR)
> +                                 break;
> + 
[...]

This patch also needs to change the '<= 0' to '< 0', doesn't it?

Ben.

-- 
Ben Hutchings
Every program is either trivial or else contains at least one bug

Attachment: signature.asc
Description: This is a digitally signed message part

Reply via email to