]> git.donarmstrong.com Git - lilypond.git/commitdiff
Issue 2078: always-changing regtest: graphviz.log
authorDavid Kastrup <dak@gnu.org>
Thu, 22 Mar 2012 18:35:25 +0000 (19:35 +0100)
committerDavid Kastrup <dak@gnu.org>
Fri, 23 Mar 2012 13:01:39 +0000 (14:01 +0100)
This sanitizes some association list usage and protects hooks against
garbage collection.

lily/grob-property.cc
scm/graphviz.scm

index 153627274d03e274abe1cdf0dc8ce00808e51a84..22c5fe2e7198e644d9001d8144587043671dbcbc 100644 (file)
@@ -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.
index 55124d0463fb4a1e75c0ba6ae4564bec54d6911c..247d30c4a7fc1bba8ede9e56965ed57de2532f6c 100644 (file)
 
 (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)))