Skip to content

Commit

Permalink
tipc: Prevent display of name table types with no publications
Browse files Browse the repository at this point in the history
This patch adds a check to prevent TIPC's name table display code
from listing a name type entry if it exists only to hold subscription
info, rather than published names.

Signed-off-by: Allan Stephens <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
  • Loading branch information
ajstephens authored and davem330 committed Jun 5, 2008
1 parent 7571521 commit 0f15d36
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions net/tipc/name_table.c
Original file line number Diff line number Diff line change
Expand Up @@ -905,6 +905,9 @@ static void nameseq_list(struct name_seq *seq, struct print_buf *buf, u32 depth,
struct sub_seq *sseq;
char typearea[11];

if (seq->first_free == 0)
return;

sprintf(typearea, "%-10u", seq->type);

if (depth == 1) {
Expand Down

0 comments on commit 0f15d36

Please sign in to comment.