forked from pool/xerces-c
20 lines
682 B
Diff
20 lines
682 B
Diff
|
--- src/xercesc/validators/DTD/DTDScanner.cpp (revision 1741478)
|
||
|
+++ src/xercesc/validators/DTD/DTDScanner.cpp (working copy)
|
||
|
@@ -2509,7 +2509,15 @@
|
||
|
{
|
||
|
while (true)
|
||
|
{
|
||
|
- const XMLCh nextCh = fReaderMgr->peekNextChar();
|
||
|
+ XMLCh nextCh;
|
||
|
+
|
||
|
+ try {
|
||
|
+ nextCh = fReaderMgr->peekNextChar();
|
||
|
+ }
|
||
|
+ catch (XMLException& ex) {
|
||
|
+ fScanner->emitError(XMLErrs::XMLException_Fatal, ex.getCode(), ex.getMessage(), NULL, NULL);
|
||
|
+ nextCh = chNull;
|
||
|
+ }
|
||
|
|
||
|
if (!nextCh)
|
||
|
{
|