Neels Hofmeyr has posted comments on this change. ( 
https://gerrit.osmocom.org/10026 )

Change subject: fix handling of invalid pchan names in vty
......................................................................


Patch Set 1: Code-Review-1

(1 comment)

https://gerrit.osmocom.org/#/c/10026/1/src/osmo-bsc/bsc_vty.c
File src/osmo-bsc/bsc_vty.c:

https://gerrit.osmocom.org/#/c/10026/1/src/osmo-bsc/bsc_vty.c@4037
PS1, Line 4037:                 if (vty->type == VTY_FILE)
nice, with CMD_ERR_NO_MATCH, you've found a way of aborting program startup 
without aborting a running application from telnet vty. For that you don't 
actually need to check vty->type == VTY_FILE, just always return 
CMD_ERR_NO_MATCH.

(Checking for VTY_FILE allows to exit(-1) or OSMO_ASSERT(false) except when in 
telnet mode, but CMD_ERR_NO_MATCH actually has exactly the desired effect, and 
my hint at VTY_FILE on redmine was just confusing you)

(only now do I actually fully realize that the entire issue exists only with 
uppercase pchan types, and that one gets proper command matching with the lower 
case ones; weird hysterical raisins I guess.)



--
To view, visit https://gerrit.osmocom.org/10026
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I97baa359464a0e94de2497bc9214b99ed2a24041
Gerrit-Change-Number: 10026
Gerrit-PatchSet: 1
Gerrit-Owner: Stefan Sperling <[email protected]>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: Neels Hofmeyr <[email protected]>
Gerrit-Comment-Date: Wed, 18 Jul 2018 23:15:09 +0000
Gerrit-HasComments: Yes
Gerrit-HasLabels: Yes

Reply via email to