xlat: treat socketlayers as a sorted array
* xlat/socketlayers.in: Add a comment that the xlat is sorted. * net.c (print_sockopt_fd_level_name): Use printxval_search instead of printxval for decoding socket layer name.
This commit is contained in:
parent
02114f254c
commit
77fef8df57
2
net.c
2
net.c
@ -400,7 +400,7 @@ print_sockopt_fd_level_name(struct tcb *tcp, int fd, unsigned int level,
|
|||||||
{
|
{
|
||||||
printfd(tcp, fd);
|
printfd(tcp, fd);
|
||||||
tprints(", ");
|
tprints(", ");
|
||||||
printxval(socketlayers, level, "SOL_??");
|
printxval_search(socketlayers, level, "SOL_??");
|
||||||
tprints(", ");
|
tprints(", ");
|
||||||
|
|
||||||
switch (level) {
|
switch (level) {
|
||||||
|
@ -1,3 +1,4 @@
|
|||||||
|
/* sort -k2,2n */
|
||||||
SOL_IP 0
|
SOL_IP 0
|
||||||
#if !(defined __alpha__ || defined __hppa__ || defined __mips__ || defined __sparc__)
|
#if !(defined __alpha__ || defined __hppa__ || defined __mips__ || defined __sparc__)
|
||||||
SOL_SOCKET 1
|
SOL_SOCKET 1
|
||||||
|
Loading…
Reference in New Issue
Block a user