Hi All,

I'm getting this problem intermittenly i.e. it works
for the first few runs, then it fails.

Getting this error:

Can't call method "entry" (or count etc) without a
package or object reference at ... (the first entry
call in the if test)

with the following code (I'm calling a function
containing this code many times with the same
connection handle):

undef $mesg;

eval
{
         $mesg = $ldap->search (
               base => "ou=my,dc=domain,dc=com",
               filter => "(mail=$recipient)",
               attrs  => ['l']
               ) || undef $mesg;

         if(defined($mesg) && $mesg->entry(0))
         {
               $My_Location =
$mesg->entry(0)->get_value('l');
         }
         else
         {
               $Unknown = 1;
         }
};

if($@)
{
         print "LDAP Error: [EMAIL PROTECTED]";
}

Why is this happening intermittently?

What am I doing wrong?

Is this a problem with the module itself?

My program is running as a daemon, and I need to
restart to get it to work.

TIA, rotis23

__________________________________
Do you Yahoo!?
Protect your identity with Yahoo! Mail AddressGuard
http://antispam.yahoo.com/whatsnewfree

Reply via email to