php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #58504 apc status page reports negative hit count
Submitted: 2009-01-13 09:12 UTC Modified: 2009-02-04 05:22 UTC
From: oliver at realtsp dot com Assigned:
Status: Closed Package: APC (PECL)
PHP Version: 5.2.5 OS: FreeBSD 7.0
Private report: No CVE-ID: None
 [2009-01-13 09:12 UTC] oliver at realtsp dot com
Description:
------------
This is a minor bug, but should be easy to fix hopefully by using a different data type.

Hits
  -1680405826
  Misses
  26634
  Request Rate (hits, misses)
  -774.30 cache requests/second
  Hit Rate
  -774.31 cache requests/second


Reproduce code:
---------------
run apc for a large number of hits and watch the count go negative...

Expected result:
----------------
rollover to zero (ie unsigned int) or don't rollover (ie larger int)

Actual result:
--------------
negative count

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2009-01-13 10:18 UTC] gopalv82 at yahoo dot com
whoa, you sure do *use* APC :)

If indeed, it's a roll over issue, I'll fix this soonish.
 [2009-01-13 19:58 UTC] shire@php.net
Yeah, FYI we also get this but I haven't had a chance to put in a fix.
 [2009-02-04 05:22 UTC] gopalv82 at yahoo dot com
http://news.php.net/php.pecl.cvs/11878

but, I was sure 64k hits was enough for anyone ;)
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri May 17 03:01:32 2024 UTC