[PATCH] fix segfault during show running-config

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/OpenBSC@lists.osmocom.org/.

Max max at sec.t-labs.tu-berlin.de
Fri Sep 21 16:33:00 UTC 2012


---
 src/vty/logging_vty.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/vty/logging_vty.c b/src/vty/logging_vty.c
index 6166f1f..71d926d 100644
--- a/src/vty/logging_vty.c
+++ b/src/vty/logging_vty.c
@@ -547,7 +547,7 @@ static int config_write_log_single(struct vty *vty, struct log_target *tgt)
 	for (i = 0; i < osmo_log_info->num_cat; i++) {
 		const struct log_category *cat = &tgt->categories[i];
 		char cat_lower[32];
-
+		if (!osmo_log_info->cat[i].name) continue;
 		/* stupid old osmo logging API uses uppercase strings... */
 		osmo_str2lower(cat_lower, osmo_log_info->cat[i].name+1);
 		osmo_str2lower(level_lower, log_level_str(cat->loglevel));
-- 
1.7.9.5


--------------080000000307010502010601--




More information about the OpenBSC mailing list