Thanks! I have removed the extra code that follows the problem code.
returns full sentences from the source files, like the one in the example above (in particular, the program succesfully outputs a new RTF file with all the lines intact). E.g.:
>>> 3.2 COMPLIANCE WITH LAWS AND REGULATIONS. While the Product is in its possession or under its, or its sub contractor's control, AKORN shall comply, or ensure that its subcontractors comply, with all applicable federal, state and local statutory and regulatory requirements regarding the manufacture, if applicable, packaging, handling transportation and storage of the Product. <<<