PHPWord
PHPWord copied to clipboard
Uninitialized string offset in MsDoc.php
When trying to parse a larger doc file I get the following stacktrace:
Uninitialized string offset: 2228225 C:\workspace\PhpOfficeUtils\vendor\phpoffice\phpword\src\PhpWord\Reader\MsDoc.php:2305 C:\workspace\PhpOfficeUtils\vendor\phpoffice\phpword\src\PhpWord\Reader\MsDoc.php:1147 C:\workspace\PhpOfficeUtils\vendor\phpoffice\phpword\src\PhpWord\Reader\MsDoc.php:1099 C:\workspace\PhpOfficeUtils\vendor\phpoffice\phpword\src\PhpWord\Reader\MsDoc.php:118 C:\workspace\PhpOfficeUtils\vendor\phpoffice\phpword\src\PhpWord\IOFactory.php:78
I tried to understand what's going on. As it seems the calculated aSed (MsDoc.php:1137) is not correct. The length of the given data string is only 1818112, why reading at index 2228225 causes this error.
Unfortunatelly my document includes sensible data why I cannot share it. If you need any further information please let me know.
Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.
I am having a similar issue, and I am not sure what's wrong. The file is created by Word for Mac.
I am having the same issue with any *.doc file generated on a mac.
The same issue here, any solution?
I am having the same issue with any *.doc file generated