This is a known bug with PGF/TikZ 2.1 (see http://groups.google.com/group/comp.text.tex/browse_thread/thread/b41b47158ac5d221/b7428bd8ca1084ae?pli=1)
Save the following patch as pgflibraryshapes.callouts.code.tex.diff and apply it to the file pgflibraryshapes.callouts.code.tex (you might want to create a backup first), e.g. by
patch -i pgflibraryshapes.callouts.code.tex.diff ${TEXMF}/tex/generic/pgf/libraries/shapes/pgflibraryshapes.callouts.code.tex
(where ${TEXMF} is the path to your local TEXMF directory)
@@ -247,9 +247,9 @@
\pgf@lib@callouts@shortenpointer%
\pgf@lib@ellipsecallout@getpoints%
\calloutpointeranchor%
- \ifx\pgf@test\pgfutil@empty%
+ \ifx\pgf@node@name\pgfutil@empty%
\else%
- \edef\pgf@sh@@temp{\noexpand\expandafter\noexpand\pgfutil@g@addto@macro\noexpand\csname pgf@sh@np@\pgf@test\noexpand\endcsname}%
+ \edef\pgf@sh@@temp{\noexpand\expandafter\noexpand\pgfutil@g@addto@macro\noexpand\csname pgf@sh@np@\pgf@node@name\noexpand\endcsname}%
\edef\pgf@sh@@@temp{%
\noexpand\def\noexpand\calloutpointeranchor{%
\noexpand\pgf@x\the\pgf@x%
@@ -568,15 +568,15 @@
\pgfmathsetlengthmacro\pointerwidth{\pgfkeysvalueof{/pgf/callout pointer width}}%
\pgf@lib@rectanglecallout@pointer%
%
- % \pgf@test = the shape name (from \pgfmultipartnode)
+ % \pgf@node@name = the shape name (from \pgfmultipartnode)
%
- \ifx\pgf@test\pgfutil@empty%
+ \ifx\pgf@node@name\pgfutil@empty%
\else%
%
% Now hack an extra saved anchor \calloutpointeranchor,
% with the new anchor for the callout pointer.
%
- \edef\pgf@sh@@temp{\noexpand\expandafter\noexpand\pgfutil@g@addto@macro\noexpand\csname pgf@sh@np@\pgf@test\noexpand\endcsname}%
+ \edef\pgf@sh@@temp{\noexpand\expandafter\noexpand\pgfutil@g@addto@macro\noexpand\csname pgf@sh@np@\pgf@node@name\noexpand\endcsname}%
\edef\pgf@sh@@@temp{%
\noexpand\def\noexpand\calloutpointeranchor{%
\noexpand\pgf@x\the\pgf@x%
@@ -862,9 +862,9 @@
\pgfextract@process\calloutpointer{%
\pgfpointanchor{pgf@lib@callout@pointer}{center}%
}%
- \ifx\pgf@test\pgfutil@empty%
+ \ifx\pgf@node@name\pgfutil@empty%
\else%
- \edef\pgf@sh@@temp{\noexpand\expandafter\noexpand\pgfutil@g@addto@macro\noexpand\csname pgf@sh@np@\pgf@test\noexpand\endcsname}%
+ \edef\pgf@sh@@temp{\noexpand\expandafter\noexpand\pgfutil@g@addto@macro\noexpand\csname pgf@sh@np@\pgf@node@name\noexpand\endcsname}%
\edef\pgf@sh@@@temp{%
\noexpand\def\noexpand\calloutpointeranchor{%
\noexpand\pgf@x\the\pgf@x%