org-plot: Correction in callback registration
commit4c37a937a7a770d9493ea6776530401ff053ab56
authorMario Frasca <mrgsfrasca@gmail.com>
Sun, 2 Nov 2014 13:53:27 +0000 (2 08:53 -0500)
committerNicolas Goaziou <mail@nicolasgoaziou.fr>
Sat, 8 Nov 2014 20:38:52 +0000 (8 21:38 +0100)
tree7f339366390a16d98811fb1d87535d642d845640
parent9f28685b29e21517dd2d4b870fec835929be882f
org-plot: Correction in callback registration

org-plot.el (org-plot/gnuplot): Correct the callback for the and
register it as soon as possible.

The data-file variable is not in the scope of the callback, one needs
to grab its value while registering the callback.  With this patch the
timer is set as soon as the file is created.  Without this patch the
timer is set at the end of a let-block, if anything goes wrong in the
let-block before the timer is set, the file will not be removed.

TINYCHANGE
lisp/org-plot.el