From 9859c05fbc351b9d6b6bcf28ac5ab49ef6ed3155 Mon Sep 17 00:00:00 2001 From: Guy Harris Date: Sat, 16 Jul 2005 01:55:58 +0000 Subject: Get rid of the newline between "radius:" and the error when trying to read the RADIUS directory. The error string from "radius_load_dictionary()" is g_malloced; free it, and g_strdup the "Could not find the radius directory" error, so we don't have to worry about constant vs. g_malloced strings. svn path=/trunk/; revision=14937 --- epan/dissectors/packet-radius.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'epan') diff --git a/epan/dissectors/packet-radius.c b/epan/dissectors/packet-radius.c index f45c8c52a5..4f2601c92f 100644 --- a/epan/dissectors/packet-radius.c +++ b/epan/dissectors/packet-radius.c @@ -802,11 +802,12 @@ proto_register_radius(void) dict = radius_load_dictionary(dir,"dictionary",&dict_err_str); } else { dict = NULL; - dict_err_str = "Could not find the radius directory"; + dict_err_str = g_strdup("Could not find the radius directory"); } if (dict_err_str) { - report_failure("radius:\n%s",dict_err_str); + report_failure("radius: %s",dict_err_str); + g_free(dict_err_str); } if (dict) { -- cgit v1.2.3