PreviewLoader: change 2^(20) to pow(2, 20)?
Scott Kostyshak
skostysh at lyx.org
Sat Mar 28 17:10:34 UTC 2020
Can someone check whether the attached changes make sense? The first
patch just changes the code to what I think is intended. But is it worth
it to include the <cmath> header for this one expression or should we
put the hardcoded value and in a comment note that it equals 2^20?
The second patch increases pow(2, 20) to pow(2, 22), which is
PID_MAX_LIMIT on most 64-bit systems, but perhaps there was a reason
pow(2, 20) was used? I don't understand the purpose of these fake PIDs
so I'm not sure.
Scott
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-Use-pow-for-raising-to-power-instead-of.patch
Type: text/x-diff
Size: 1048 bytes
Desc: not available
URL: <http://lists.lyx.org/pipermail/lyx-devel/attachments/20200328/1daa5c8e/attachment.patch>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0002-PreviewLoader-start-fake-pids-after-PID_MAX_LIMIT.patch
Type: text/x-diff
Size: 941 bytes
Desc: not available
URL: <http://lists.lyx.org/pipermail/lyx-devel/attachments/20200328/1daa5c8e/attachment-0001.patch>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: not available
URL: <http://lists.lyx.org/pipermail/lyx-devel/attachments/20200328/1daa5c8e/attachment.asc>
More information about the lyx-devel
mailing list