Integrate patch from
http://code.google.com/p/xdocreport/issues/detail?id=225