On Thu, 2011-03-03 at 09:42 -0500, Kevin Hunter wrote: So, the reason for the negative value is in the following line
> 484: sal_Int32 nIntervalCount = static_cast<sal_Int32>( fSub / > m_rIncrement.Distance ); where fSub / m_rIncrement.Distance value (which is double divided by double) is still positive *but* way above the numeric limit of sal_Int32, which causes the casted value nIntervalCount to become negative (probably) by way of bitwise re-interpretation. Capping the value of fSub / m_rIncrement.Distance to std::numeric_limits<sal_Int32>::max() keeps the value of nIntervalCount positive. Even with this change, though, the displayed graph showed on difference. So, no data loss here. Now, can someone please sign off of this, or is this change still too risky or questionable? :-) Thanks, Kohei -- Kohei Yoshida, LibreOffice hacker, Calc <kyosh...@novell.com> _______________________________________________ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice