[PATCH 3/6] pacmd: Add optional argument for quiet mode

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello,

> > +        pa_zero(pollfd);
> > +        p = pollfd;
> > +
> > +        watch_socket = p++;
> > +        watch_socket->fd = fd;
> > +        watch_socket->events = POLLIN;
> > +
> > +        if ((res = pa_poll(pollfd, p-pollfd, 100)) < 0) {
> > +            if (errno == EINTR)
> > +                continue;
> > +
> > +            pa_log(_("poll(): %s"), strerror(errno));
> > +            goto quit;
> > +        }
> 
> The setup of watch_socket/pollfd and the call (why isn't watch_socket passed?)
> is really awkward to me. Why such strange code?

right, thanks for having a look; it's just the same code used also a few 
lines down :)
since there is just one handle to watch, the code looks awkward 
and could/should be streamlined

the entire block might go away if we decide to drop backward compatibility 
as David suggested

regards, p.

-- 

Peter Meerwald
+43-664-2444418 (mobile)


[Index of Archives]     [Linux Audio Users]     [AMD Graphics]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux