Re: Full-Bore Linear Panic

From: Date: Wed, 09 Aug 2000 02:06:58 +0000
Subject: Re: Full-Bore Linear Panic
References: 1 2  Groups: php.general 
Request: Send a blank email to php-general+get-10821@lists.php.net to get a copy of this message
Are you using any options on your INSERT, such as INSERT DELAYED or setting LOW_PRIORITY? Maybe the record just wasn't written yet when you went looking for it. Jeff David VanHorn wrote: > > I just hit a large bug. > > As part of my authentication, I pass the browser a random cookie for use on > the next page. > I then get the cookie the browser sent me, and check the DB. If that cookie > exists, then I write the new cookie for next time. If not, I do nothing, > and the cookie I passed is not valid (since it didn't get written). > > That works fine.. > > Later in some scripts, I use the cookie value to pull up the user information. > Here, it fails, UNLESS: I add in sleep(1) before the cookie check. > > In the failed case, when I check the cookie value I was looking for, it IS > present in the databaase, and a manual query through MySQL confirms this. > > I can absolutely trigger this problem by removing the sleep statement > before the second cookie check. > > It seems that when I stored the cookie, it didn't happen in time for the > next part of the script to check. > > -- > Where's dave? > http://www.findu.com/cgi-bin/find.cgi?kc6ete-9 > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net > For additional commands, e-mail: php-general-help@lists.php.net > To contact the list administrators, e-mail: php-list-admin@lists.php.net

« previous php.general (#10821) next »