As of cvs snapshot 20050526, the printflags() semantics is error prone. Client is expected to check return code of this function, which is easy to forget. There are 32 cases in current codebase where return code is not checked and therefore flag value may be omitted. For example: $ strace -e trace=capget getpcaps $$ capget(0x12345678, 12345, {, , }) = 0 Capabilities for `12345': = I suggest to add third argument to printflags() with similar meaning to the third argument of printxval(). As result, in most cases printflags() return code will be unneeded and clients will look more clear.
Created attachment 115039 [details] strace-4.5.11-alt-printflags.patch Proposed change.
Looks good, thanks for the patch. It's in.