This is merely a historical archive of years 2008-2021, before the migration to mailman3.
A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.
osmith gerrit-no-reply at lists.osmocom.orgosmith has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmocore/+/25348 )
Change subject: vty: add vty_out_uptime() print the uptime to the vty
......................................................................
Patch Set 2: Code-Review-1
(1 comment)
https://gerrit.osmocom.org/c/libosmocore/+/25348/2/src/vty/vty.c
File src/vty/vty.c:
https://gerrit.osmocom.org/c/libosmocore/+/25348/2/src/vty/vty.c@352
PS2, Line 352: return vty_out(vty, "%dd %dh %dm %ds", d, h, m, s);
This function is very similar to DEFUN(show_uptime.. from command.c. Can you refactor that function to use the new function? Something like this:
DEFUN(show_uptime,
show_uptime_cmd, "show uptime", SHOW_STR "Displays how long the program has been running\n")
{
vty_out(vty, "%s has been running for ", host.app_info->name);
vty_out_uptime(vty, starttime);
vty_out(vty, "%s", VTY_NEWLINE);
return CMD_SUCCESS;
}
Also startime is a global variable name in command.c, but gets added here as parameter to vty_out_uptime in vty.c. Maybe rename one of them?
--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/25348
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I264a3f49096b96646e0a1f5366623ac20d860793
Gerrit-Change-Number: 25348
Gerrit-PatchSet: 2
Gerrit-Owner: lynxis lazus <lynxis at fe80.eu>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: osmith <osmith at sysmocom.de>
Gerrit-Reviewer: pespin <pespin at sysmocom.de>
Gerrit-Comment-Date: Tue, 07 Sep 2021 09:12:09 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20210907/4e282e77/attachment.htm>