Apache FOP Code update

Code update
by
AD
:

Minor fix: correctly set negative values for ipd/bpd to zero.