HomePhorge

Fix Feed Times on 32 Bit Servers

Description

Fix Feed Times on 32 Bit Servers

Summary:
The feed time is stored as the upper 32 bits of
PhabricatorFeedStoryData::chronologicalKey. These bits were previously accessed
by right shifting, which does not work properly on 32 bit machines (the result
is PHP_INT_MAX). We now attempt to use the bc extension (if available) and fall
back on mysql math otherwise. (See T500, D912).

Test Plan:
The calculation is unchanged for 64 bit machines. I checked both
paths on a 32 bit machine with bc extension available by setting the appropriate
if-condition to false and true.

Reviewers: epriestley

Reviewed By: epriestley

CC: ddfisher, aran, epriestley

Differential Revision: https://secure.phabricator.com/D1726

Details

Provenance
David FisherAuthored on Feb 28 2012, 9:03 PM
epriestleyCommitted on Feb 28 2012, 9:04 PM
themackabuPushed on Mar 25 2025, 8:07 PM
Parents
rP9b318e4044c8: Respect username letter case in Remarkup
Branches
Unknown
Tags
Unknown

Event Timeline