summaryrefslogtreecommitdiff
path: root/modules/commands/ns_alist.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'modules/commands/ns_alist.cpp')
-rw-r--r--modules/commands/ns_alist.cpp13
1 files changed, 11 insertions, 2 deletions
diff --git a/modules/commands/ns_alist.cpp b/modules/commands/ns_alist.cpp
index d273ec59f..6ccbe94ba 100644
--- a/modules/commands/ns_alist.cpp
+++ b/modules/commands/ns_alist.cpp
@@ -86,8 +86,17 @@ class CommandNSAList : public Command
entry["Number"] = stringify(chan_count);
entry["Channel"] = (ci->HasExt("CS_NO_EXPIRE") ? "!" : "") + ci->name;
- for (unsigned j = 0; j < access.size(); ++j)
- entry["Access"] = entry["Access"] + ", " + access[j]->AccessSerialize();
+ for (unsigned j = 0; j < access.paths.size(); ++j)
+ {
+ ChanAccess::Path &p = access.paths[i];
+
+ // not interested in indirect access
+ if (p.size() != 1)
+ continue;
+
+ ChanAccess *a = p[0];
+ entry["Access"] = entry["Access"] + ", " + a->AccessSerialize();
+ }
entry["Access"] = entry["Access"].substr(2);
entry["Description"] = ci->desc;
list.AddEntry(entry);