Decode fd_set into array of file descriptors

shankarapailoor shankarapailoor at gmail.com
Sat Dec 22 14:59:10 UTC 2018


>Do you suggest to print bit sets as if they were regular arrays
of integer types?

Yes that would be my suggestion. [a, b, c] could just mean a
collection that consists of a, b, c. So an fd_set or signal mask
represented as [a, b, c] seems just as interpretable to me as [a b c]
even under bitwise operations like ~. For example, with the fd_set
bitset I only want to see a list of file descriptors.

On Fri, Dec 21, 2018 at 4:33 PM Dmitry V. Levin <ldv at altlinux.org> wrote:
>
> Hi,
>
> On Wed, Dec 19, 2018 at 08:41:39PM -0800, shankarapailoor wrote:
> > Hi!
> >
> > I was looking at the decoding of select system call and I noticed that
> > fd_set  is decoded as [fd1 fd2 fd3 ..]. Is it ok to change this to be
> > an array of file descriptors?  Attached is a patch which changes this
> > to be an array of file descriptors like [fd1, fd2, fd3, ...]. Let me
> > know what you think.
>
> Do you suggest to print bit sets as if they were regular arrays
> of integer types?
>
> We had a rather short and inconclusive discussion about bit sets recently,
> please have a look at the thread starting at
> https://lists.strace.io/pipermail/strace-devel/2018-October/008389.html
>
>
> --
> ldv
> --
> Strace-devel mailing list
> Strace-devel at lists.strace.io
> https://lists.strace.io/mailman/listinfo/strace-devel



-- 
Regards,
Shankara Pailoor


More information about the Strace-devel mailing list