From: David Kastrup Date: Thu, 22 Mar 2012 18:35:25 +0000 (+0100) Subject: Issue 2078: always-changing regtest: graphviz.log X-Git-Tag: release/2.15.35-1~20 X-Git-Url: https://git.donarmstrong.com/?a=commitdiff_plain;h=92b4c250ab1055463a2cd4b1b11e599d04505aac;p=lilypond.git Issue 2078: always-changing regtest: graphviz.log This sanitizes some association list usage and protects hooks against garbage collection. --- diff --git a/lily/grob-property.cc b/lily/grob-property.cc index 153627274d..22c5fe2e71 100644 --- a/lily/grob-property.cc +++ b/lily/grob-property.cc @@ -36,8 +36,8 @@ print_property_callback_stack () } #endif -static SCM modification_callback = SCM_EOL; -static SCM cache_callback = SCM_EOL; +static Protected_scm modification_callback = SCM_EOL; +static Protected_scm cache_callback = SCM_EOL; /* FIXME: this should use ly:set-option interface instead. diff --git a/scm/graphviz.scm b/scm/graphviz.scm index 55124d0463..247d30c4a7 100644 --- a/scm/graphviz.scm +++ b/scm/graphviz.scm @@ -37,18 +37,18 @@ (define (add-cluster graph node-id cluster-name) (let* ((cs (clusters graph)) - (cluster (assq cluster-name cs)) + (cluster (assoc cluster-name cs)) (already-in-cluster (if cluster (cdr cluster) '()))) - (set-clusters! graph (assq-set! cs + (set-clusters! graph (assoc-set! cs cluster-name (cons node-id already-in-cluster))))) (define (add-node graph label . cluster-name) (let* ((ns (nodes graph)) (id (length ns))) - (set-nodes! graph (assq-set! ns id label)) + (set-nodes! graph (assv-set! ns id label)) (if (and (not (null? cluster-name)) (string? (car cluster-name))) (add-cluster graph id (car cluster-name)))