Commit 699caabd authored by Pavel Emelyanov's avatar Pavel Emelyanov

show: Add pipes string to fdinfo output

Signed-off-by: 's avatarPavel Emelyanov <xemul@parallels.com>
parent ed456a1b
...@@ -63,11 +63,12 @@ static char *fdtype2s(u8 type) ...@@ -63,11 +63,12 @@ static char *fdtype2s(u8 type)
[FDINFO_CWD] = "cwd", [FDINFO_CWD] = "cwd",
[FDINFO_EXE] = "exe", [FDINFO_EXE] = "exe",
[FDINFO_INETSK] = "isk", [FDINFO_INETSK] = "isk",
[FDINFO_PIPE] = "pipe",
}; };
if (type > FDINFO_UND && type < FD_INFO_MAX) if (type > FDINFO_UND && type < FD_INFO_MAX)
return fdtypes[type]; return fdtypes[type];
snprintf(und, sizeof(und), "x%02d\n", (int)type); snprintf(und, sizeof(und), "x%03d\n", (int)type);
return und; return und;
} }
...@@ -84,7 +85,7 @@ void show_files(int fd_files, struct cr_options *o) ...@@ -84,7 +85,7 @@ void show_files(int fd_files, struct cr_options *o)
if (ret <= 0) if (ret <= 0)
goto out; goto out;
pr_msg("type: %s addr: %16lx id: %8x", pr_msg("type: %5s addr: %16lx id: %8x",
fdtype2s(e.type), e.addr, e.id); fdtype2s(e.type), e.addr, e.id);
pr_msg("\n"); pr_msg("\n");
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment