From 3803b501a79071187324d75efdf1ea9e3437347f Mon Sep 17 00:00:00 2001 From: Robert Lehmann Date: Fri, 26 Nov 2010 09:46:52 +0100 Subject: [PATCH] Use a clean getattr() instead of eval(). --- libbe/command/list.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libbe/command/list.py b/libbe/command/list.py index 06249a0..f348d5c 100644 --- a/libbe/command/list.py +++ b/libbe/command/list.py @@ -156,7 +156,7 @@ class List (libbe.command.Command): raise libbe.command.UserError( 'Invalid sort on "%s".\nValid sorts:\n %s' % (cmp, '\n '.join(AVAILABLE_CMPS))) - cmp_list.append(eval('libbe.bug.cmp_%s' % cmp)) + cmp_list.append(getattr(libbe.bug, 'cmp_%s' % cmp)) status = parse_status(params['status']) severity = parse_severity(params['severity'], important=params['important']) -- 2.26.2