Change in ...libosmocore[master]: fix: vty crash by logging to killed telnet session

pespin gerrit-no-reply at lists.osmocom.org
Thu Aug 22 10:25:44 UTC 2019


pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmocore/+/15265 )

Change subject: fix: vty crash by logging to killed telnet session
......................................................................


Patch Set 1:

(6 comments)

https://gerrit.osmocom.org/#/c/15265/1//COMMIT_MSG 
Commit Message:

https://gerrit.osmocom.org/#/c/15265/1//COMMIT_MSG@11 
PS1, Line 11: segfaults: the vty->obuf is already NULL.
Why do we try to send a message to a killed session first of all? That seems to be the route of the issue.


https://gerrit.osmocom.org/#/c/15265/1//COMMIT_MSG@13 
PS1, Line 13: In vty_out(), guard against this situation by not composing an output if
Fine with this part so far.


https://gerrit.osmocom.org/#/c/15265/1//COMMIT_MSG@16 
PS1, Line 16: Also guard all buffer_*() functions against a NULL buffer argument, which
this looks like a hack to fix other parts of the code which may be wrong, and looks like it should be fixed in other places rather than here.


https://gerrit.osmocom.org/#/c/15265/1//COMMIT_MSG@20 
PS1, Line 20: Related: OS#4164
This ticket doesn't look related to me.


https://gerrit.osmocom.org/#/c/15265/1/src/vty/buffer.c 
File src/vty/buffer.c:

https://gerrit.osmocom.org/#/c/15265/1/src/vty/buffer.c@95 
PS1, Line 95: 	if (!b)
I don't think these checks are really needed to fix the issue at hand, so at least they should go into a separate commit.


https://gerrit.osmocom.org/#/c/15265/1/src/vty/vty.c 
File src/vty/vty.c:

https://gerrit.osmocom.org/#/c/15265/1/src/vty/vty.c@266 
PS1, Line 266: 			 * of this same (killed) telnet session. See OS#4146. */
OS#4146 (https://osmocom.org/issues/4146) seems non-related to what you say here, probably wrong ticket number.



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

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: Idca3f54dc986abf6784790c12e69e02bdf77cb41
Gerrit-Change-Number: 15265
Gerrit-PatchSet: 1
Gerrit-Owner: neels <nhofmeyr at sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-CC: pespin <pespin at sysmocom.de>
Gerrit-Comment-Date: Thu, 22 Aug 2019 10:25:44 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Gerrit-MessageType: comment
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20190822/75e233c0/attachment.html>


More information about the gerrit-log mailing list