You are correct, sir! I'll need you to please file an errata report with PacktPub.com. It looks like a line of code got lost somewhere. In any case, just add this line right before line 22:<br><br>my $e = $con->recvEvent();<br>
<br>That should do the trick. Not sure what happened with that code sample but I'll ask Packt to fix it. However, I need you to open the errata report.<br><br>Thanks,<br>MC<br><br><div class="gmail_quote">2012/2/28 ÷ÌÁÄÉÓÌÁ× çÒÉÛÉÎ <span dir="ltr"><<a href="mailto:Vladislav.Grishin@vts24.ru">Vladislav.Grishin@vts24.ru</a>></span><br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div link="blue" vlink="purple" lang="RU">
<div>
<p class="MsoNormal"><font face="Courier New"><span style="font-size:10.0pt;font-family:"Courier New"" lang="EN-US">I have FreeSWITCH Version
1.0.6 (hacked-20110607T065231Z) on Centos 5.5<u></u><u></u></span></font></p>
<p class="MsoNormal"><font face="Courier New"><span style="font-size:10.0pt;font-family:"Courier New"" lang="EN-US"><u></u>š<u></u></span></font></p>
<p class="MsoNormal"><font face="Courier New"><span style="font-size:10.0pt;font-family:"Courier New"" lang="EN-US">I run script /usr/src/freeswitch-1.0.6/libs/esl/perl/<a href="http://logger.pl" target="_blank">logger.pl</a>š
- all ok.<u></u><u></u></span></font></p>
<p class="MsoNormal"><font face="Courier New"><span style="font-size:10.0pt;font-family:"Courier New"" lang="EN-US"><u></u>š<u></u></span></font></p>
<p class="MsoNormal"><font face="Courier New"><span style="font-size:10.0pt;font-family:"Courier New"" lang="EN-US">Script from 59 page of FreeSWITCH
cookbook finishes with an error<u></u><u></u></span></font></p>
<p class="MsoNormal"><font face="Courier New"><span style="font-size:10.0pt;font-family:"Courier New"" lang="EN-US"><u></u>š<u></u></span></font></p>
<p class="MsoNormal"><font face="Courier New"><span style="font-size:10.0pt;font-family:"Courier New"" lang="EN-US">Global symbol "$e"
requires explicit package name at ./<a href="http://cdr_to_file.pl" target="_blank">cdr_to_file.pl</a> line 22.<u></u><u></u></span></font></p>
<p class="MsoNormal"><font face="Courier New"><span style="font-size:10.0pt;font-family:"Courier New"" lang="EN-US">Execution of
./<a href="http://cdr_to_file.pl" target="_blank">cdr_to_file.pl</a> aborted due to compilation errors.<u></u><u></u></span></font></p>
<p class="MsoNormal"><font face="Courier New"><span style="font-size:10.0pt;font-family:"Courier New"" lang="EN-US"><u></u>š<u></u></span></font></p>
<p class="MsoNormal"><font face="Courier New"><span style="font-size:10.0pt;font-family:"Courier New"" lang="EN-US">22 line is <u></u><u></u></span></font></p>
<p class="MsoNormal"><font face="Courier New"><span style="font-size:10.0pt;font-family:"Courier New"" lang="EN-US"><u></u>š<u></u></span></font></p>
<p class="MsoNormal"><font face="Courier New"><span style="font-size:10.0pt;font-family:"Courier New"" lang="EN-US">ššš my @raw_data = split
"\n",$e->serialize();<u></u><u></u></span></font></p>
<p class="MsoNormal"><font face="Courier New"><span style="font-size:10.0pt;font-family:"Courier New"" lang="EN-US"><u></u>š<u></u></span></font></p>
<p class="MsoNormal"><font face="Courier New"><span style="font-size:10.0pt;font-family:"Courier New"" lang="EN-US"><u></u>š<u></u></span></font></p>
<p class="MsoNormal"><font face="Courier New"><span style="font-size:10.0pt;font-family:"Courier New"" lang="EN-US">Vladislav Grishin<u></u><u></u></span></font></p>
</div>
</div>
<br>_________________________________________________________________________<br>
Professional FreeSWITCH Consulting Services:<br>
<a href="mailto:consulting@freeswitch.org">consulting@freeswitch.org</a><br>
<a href="http://www.freeswitchsolutions.com" target="_blank">http://www.freeswitchsolutions.com</a><br>
<br>
FreeSWITCH-powered IP PBX: The CudaTel Communication Server<br>
<a href="http://www.cudatel.com" target="_blank">http://www.cudatel.com</a><br>
<br>
Official FreeSWITCH Sites<br>
<a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
<a href="http://wiki.freeswitch.org" target="_blank">http://wiki.freeswitch.org</a><br>
<a href="http://www.cluecon.com" target="_blank">http://www.cluecon.com</a><br>
<br>
FreeSWITCH-users mailing list<br>
<a href="mailto:FreeSWITCH-users@lists.freeswitch.org">FreeSWITCH-users@lists.freeswitch.org</a><br>
<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
<a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
<br></blockquote></div><br>