Re: [PHP-DEV] Question for Zeev, Zak or Georg - mysql_query and possible integer overflow?
[email protected] (Matt Flaherty) 25 Mar 2003 14:27:28 +0000
| Newsgroups | php.dev |
|---|---|
| Organization | Boltblue International Ltd. |
| Message-ID | <1048602448.14363.74.camel@Xflay> |
Thanks Wez, If all that happens is the query will fail, I can live with that. It's a simple SELECT query called over and over again. If the integer wraps around negative, I'm guessing that would probably have undesirable effects. If not, then I can let it run forever. What I don't want is something like a segfault. I'm considering making the application restart itself periodically to clear out the cobwebs. -Matt On Tue, 2003-03-25 at 14:12, Wez Furlong wrote: > Hi Matt, > > Yes, there is a risk of overflow. > >From my understanding, the id is signed, so you will hit overflow at 2G > rather than 4G resources. > This applies to any/all PHP/ZE resources. > > I'm not sure what happens when it overflows; it seems like the query > would fail. > > You could design your application so that it re-runs itself when the > query fails (pcntl_exec(), or one of the other execution functions). > > --Wez. >