library: VTY: Allow hyphens in VTY prompt

Old versions of osmo-pcu print "Osmo-PCU" as VTY prompt. This commit
allows supporting this kind of prompt.

Change-Id: Ia5acbbe5828901726f7f15c4a99d596e94914c4b
This commit is contained in:
Pau Espin 2019-12-04 16:59:29 +01:00 committed by laforge
parent beba4e56a0
commit 1a4d4e97b7
1 changed files with 3 additions and 3 deletions

View File

@ -63,9 +63,9 @@ module Osmocom_VTY_Functions {
T.start;
alt {
[] pt.receive(pattern "\w+" & VTY_VIEW_SUFFIX) { };
[] pt.receive(pattern "\w+\# ") { };
[] pt.receive(pattern "\w+\(*\)\# ") { };
[] pt.receive(pattern "[\w-]+" & VTY_VIEW_SUFFIX) { };
[] pt.receive(pattern "[\w-]+\# ") { };
[] pt.receive(pattern "[\w-]+\(*\)\# ") { };
[] pt.receive(t_vty_unknown) {
testcase.stop(fail, "VTY: Unknown Command");
};