Skip to content

Commit

Permalink
Minor fix to untrace classes properly
Browse files Browse the repository at this point in the history
  • Loading branch information
R. Saravanan committed Oct 31, 2012
1 parent 4a8c0b8 commit 8ed96a3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions otrace.py
Expand Up @@ -2740,7 +2740,7 @@ def cmd_untrace(self, cmd, comps, line, rem_line):
elif not isinstance(trace_value, basestring):
return (out_str, "Cannot untrace %s" % trace_value)

fullname = OTrace.remove_trace(trace_name, parent=parent_obj)
fullname = OTrace.remove_trace(trace_value, parent=parent_obj)
out_str = "untraced %s" % fullname

return (out_str, err_str)
Expand Down Expand Up @@ -4128,7 +4128,7 @@ def remove_trace(cls, method=None, parent=None):
if method == "*":
cls.trace_all = False
retvalue = "*"
elif method.startswith(PATH_SEP):
elif isinstance(method, basestring) and method.startswith(PATH_SEP):
# Untrace entity key
try:
del cls.trace_keys[method]
Expand Down

0 comments on commit 8ed96a3

Please sign in to comment.