From db1cec0536ec5f4da6e653797033905ef4c5f872 Mon Sep 17 00:00:00 2001 From: Juho Snellman Date: Sat, 30 Oct 2010 11:39:14 +0000 Subject: [PATCH] 1.0.43.80: Allow UNTRACE of functions that are no longer defined * Patch lp#667657 from Attila Lendvai --- NEWS | 4 +++- src/code/ntrace.lisp | 11 ++++++++--- version.lisp-expr | 2 +- 3 files changed, 12 insertions(+), 5 deletions(-) diff --git a/NEWS b/NEWS index 9febed1..4c6b558 100644 --- a/NEWS +++ b/NEWS @@ -86,7 +86,9 @@ changes relative to sbcl-1.0.43: not just Darwin. (lp#451111) * bug fix: SB-BSD-SOCKETS and SB-SIMPLE-STREAMS could leave stale finalizers around when core was saved, which could cause undefined behaviour when the - core was reified. + core was reified. + * bug fix: Allow UNTRACE of functions that are no longer defined + (lp#667657, thanks to Attila Lendvai) changes in sbcl-1.0.43 relative to sbcl-1.0.42: * incompatible change: FD-STREAMS no longer participate in the serve-event diff --git a/src/code/ntrace.lisp b/src/code/ntrace.lisp index ce60ee6..6e32b1d 100644 --- a/src/code/ntrace.lisp +++ b/src/code/ntrace.lisp @@ -124,9 +124,13 @@ (error "can't trace special form ~S" x)) ((macro-function x)) (t - (values (fdefinition x) t)))) + (values (when (fboundp x) + (fdefinition x)) + t)))) (function x) - (t (values (fdefinition x) t))) + (t (values (when (fboundp x) + (fdefinition x)) + t))) (typecase res (closure (values (sb-kernel:%closure-fun res) @@ -647,7 +651,8 @@ are evaluated in the null environment." (info (gethash fun *traced-funs*))) (cond ((not info) - (warn "Function is not TRACEd: ~S" function-or-name)) + (when fun + (warn "Function is not TRACEd: ~S" function-or-name))) (t (cond ((trace-info-encapsulated info) diff --git a/version.lisp-expr b/version.lisp-expr index 6fe2629..465e42d 100644 --- a/version.lisp-expr +++ b/version.lisp-expr @@ -17,4 +17,4 @@ ;;; checkins which aren't released. (And occasionally for internal ;;; versions, especially for internal versions off the main CVS ;;; branch, it gets hairier, e.g. "0.pre7.14.flaky4.13".) -"1.0.43.79" +"1.0.43.80" -- 1.7.10.4