X-Git-Url: http://git.vanrenterghem.biz/git.ikiwiki.info.git/blobdiff_plain/ab575a4b6985d38969069757bb374aa8f1013019..885bff723998525c10d7ea8ad295547f5fcc939a:/IkiWiki/Plugin/graphviz.pm diff --git a/IkiWiki/Plugin/graphviz.pm b/IkiWiki/Plugin/graphviz.pm index c91c92fec..4ed8b89f1 100644 --- a/IkiWiki/Plugin/graphviz.pm +++ b/IkiWiki/Plugin/graphviz.pm @@ -37,10 +37,10 @@ sub render_graph (\%) { $src .= "}\n"; # Use the sha1 of the graphviz code as part of its filename. - eval q{use Digest::SHA1}; + eval q{use Digest::SHA}; error($@) if $@; my $dest=$params{page}."/graph-". - IkiWiki::possibly_foolish_untaint(Digest::SHA1::sha1_hex($src)). + IkiWiki::possibly_foolish_untaint(Digest::SHA::sha1_hex($src)). ".png"; will_render($params{page}, $dest); @@ -71,7 +71,8 @@ sub render_graph (\%) { writefile($dest, $config{destdir}, $png, 1); } else { - # can't write the file, so embed it in a data uri + # in preview mode, embed the image in a data uri + # to avoid temp file clutter eval q{use MIME::Base64}; error($@) if $@; return "