You are viewing a plain text version of this content. The canonical link for it is here.
Posted to c-users@xerces.apache.org by José Rui Simões <jo...@criticalsoftware.com> on 2007/05/23 12:53:13 UTC

Problem importing dtd settings file in MS Windows

Dear all,

I have a problem that has been annoying me for the last few days.

I am building a test framework. Our test cases are created in an xml 
file which depicts the test case, since some settings are common to all 
the test cases we have a dtd file with these settings. My problem is 
that the xml and dtd files are correctly parsed in Ubuntu 7.04 but 
aren't in MS Windows.

XML file:

<?xml version = "1.0" encoding = "UTF-8"?>
<!DOCTYPE execution [
    <!-- settings -->
    <!ENTITY % settings SYSTEM "settings.dtd">
    %settings;
]>

<execution>
    <outputfiles deleteprevious="true"></outputfiles>
    <testmanager>
   
    <outputter class="CAggregOutputter" create="true" level="20" 
name="agregoutputter" >
            <outputter class="CConsoleOutputter" create="true" 
level="20" name="consoleoutputter" />
            <outputter class="CBufferedFileOutputter" create="true" 
level="20" name="bufferedfileoutputter" />
        </outputter>
       
        <!--&defaultuserinteraction;-->
        <userinteraction waittoend="true" rank="0" attachdebugger="false" />
        <exception handlesystem="true" />
       
        <resultmanager class="CMsgCreatorResultManager" create="true" 
name="resultmanager">
            <xmlfile>./result-test-msg-id.xml</xmlfile>
        </resultmanager>
       
        <thread name="default" create="true">
   
        <scheduler class="CSchedulerStepInterleaving" create="true" 
name="scheduler" />
           
            <syncgroup class="CMsgCreatorSyncGroup" create="true" 
name="test_msg_id">
               
                <resourcepool class="CRCP_Integer" create="true" 
name="msg-id">
                    <range begin="0" end="6" step="1" />
                </resourcepool>
               
                <resourcepool class="CRCP_Integer" create="true" 
name="msg-destination">
                    <range begin="0" end="128" step="32" />
                </resourcepool>
               
                <resourcepool class="CRCP_String" create="true" 
name="name_of_tester">
                    <resource class="CRSC_String" create="true" 
name="user login"></resource>
                </resourcepool>
                   
                <resourcepool class="CRCP_String" create="true" 
name="name_of_tag">
                    <resource class="CRSC_String" create="true" 
name="cvs tag"></resource>
                </resourcepool>
               
                <test class="CTestMsgID" create="true" name="TestMsgID">
                    <skipto iteration="0"/>
                </test>
           
            </syncgroup>
       
        </thread>
       
    <run times="1" />
       
    </testmanager>
       
</execution>


DTD file:

<!ENTITY outputLvl "20">
<!ENTITY name_of_tester "user login">
<!ENTITY name_of_tag "cvs tag">
<!ENTITY defaultuserinteraction '<userinteraction waittoend="true" 
rank="0" attachdebugger="false" />'>
<!ENTITY defaultexception '<exception handlesystem="true" />'>

the parsing is done using the following code

The code where it the problem occurs is this section.
CODE:

    XMLPlatformUtils::Initialize();
    m_pcXMLParser = new XercesDOMParser ();

    m_strURL = str_url;

    m_pcXMLParser->setCreateEntityReferenceNodes(false);

    // If we have an URL create an input source:
    if (!m_strURL.empty ()) {
        m_pcInputSource = new URLInputSource (XMLURL (m_strURL.c_str ()));

        m_pcXMLParser->parse (*m_pcInputSource);


        if (m_pcXMLParser->getDocument () == NULL)
            throw TESTEXCEPTION("Found empty xml document. Possibly 
tried to open wrong document(see the next files: setings.dtd,..).");

        if (m_pcXMLParser->getDocument ()->getDocumentElement () == NULL)
            throw TESTEXCEPTION("Found empty xml document. Possibly 
tried to open wrong document(see the next files: setings.dtd,..).");

    } else
        m_pcInputSource = NULL;


In Windows it always returns null in the "m_pcXMLParser->getDocument 
()->getDocumentElement ()" line. I have noticed that if I remove the 
"%settings" line in the XML file it does not return null but it also 
doesn't import the settings, so no use for this solution.

I have been searching google and the user mailing list for something 
similar but couldn't find anything. One more thing I'm using the static 
version of Xerces-C 2.7 library.

Hope you can help me, any more info you need please ask.

Thanks in advance.

Kind Regards

-- 

José Rui Simões

Junior Engineer

Critical Software, SA

Parque Industrial de Taveiro, Lote 48
3045-504 Coimbra, Portugal
Tel:+351.239 989 100 Fax:+351.239 989 119
http://www.criticalsoftware.com <http://www.criticalsoftware.com/>
jose-r-simoes@criticalsoftware.com 
<mailto:jose-r-simoes%40criticalsoftware.com>



Re: Problem importing dtd settings file in MS Windows

Posted by José Rui Simões <jo...@criticalsoftware.com>.
Alberto,

thanks very much the problem was exactly that.

Kind Regards

José Rui Simões

Junior Engineer

Critical Software, SA

Parque Industrial de Taveiro, Lote 48
3045-504 Coimbra, Portugal
Tel:+351.239 989 100 Fax:+351.239 989 119
http://www.criticalsoftware.com <http://www.criticalsoftware.com/>
jose-r-simoes@criticalsoftware.com 
<mailto:jose-r-simoes%40criticalsoftware.com>




Alberto Massari wrote:
> Jose,
> you will have problems using those URLs: try using 
> file:///d:/Cvsroot/critical/rd-defense/implementation/testframework/msg-creator-tfw/xml/run_test_msg_id.xml, 
> or use a LocalFileInputSource with the 
> d:\Cvsroot\critical\rd-defense\implementation\testframework\msg-creator-tfw\xml\run_test_msg_id.xml 
> instead of a URLInputSource
>
> Alberto
>
> At 14.47 23/05/2007 +0100, José Rui Simões wrote:
>> Hi Alberto,
>>
>> in Windows the str_url string has the following value:
>>
>> file:d:\Cvsroot\critical\rd-defense\implementation\testframework\msg-creator-tfw\xml\run_test_msg_id.xml 
>>
>>
>> in Linux it has the following value:
>>
>> file:/home/jr-simoes/Projects/msg-creator-tfw/core/../xml/run_test_msg_id.xml 
>>
>>
>> These are essentially the same path so the problem isn't here.
>>
>> Do you have any more suggestions.
>>
>> Kind Regards.
>>
>> José Rui Simões
>>
>> Junior Engineer
>>
>> Critical Software, SA
>>
>> Parque Industrial de Taveiro, Lote 48
>> 3045-504 Coimbra, Portugal
>> Tel:+351.239 989 100 Fax:+351.239 989 119
>> http://www.criticalsoftware.com <http://www.criticalsoftware.com/>
>> jose-r-simoes@criticalsoftware.com 
>> <mailto:jose-r-simoes%40criticalsoftware.com>
>>
>>
>>
>>
>> Alberto Massari wrote:
>>> At 13.41 23/05/2007 +0100, José Rui Simões wrote:
>>>> Do you mean the "settings.dtd" part next to the SYSTEM keyword in 
>>>> the Entity declaration?
>>>
>>> No, I mean the str_url that's used to initialize the URLInputSource 
>>> of the XML file:
>>>
>>>    m_strURL = str_url;
>>>
>>>    m_pcXMLParser->setCreateEntityReferenceNodes(false);
>>>
>>>    // If we have an URL create an input source:
>>>    if (!m_strURL.empty ()) {
>>>        m_pcInputSource = new URLInputSource (XMLURL (m_strURL.c_str 
>>> ()));
>>>
>>> Because that is the base URL used to resolve the settings.dtd, and 
>>> it could be the cause of the 'DTD file not found' error.
>>>
>>> Alberto
>>>
>>>
>>>> if that's it it's the same the folder scheme is the same.
>>>>
>>>> Folder layout:
>>>>
>>>> main folder\
>>>>    core code\
>>>>    some helpers\
>>>>    xml and dtd files\
>>>>
>>>> José Rui Simões
>>>>
>>>> Junior Engineer
>>>>
>>>> Critical Software, SA
>>>>
>>>> Parque Industrial de Taveiro, Lote 48
>>>> 3045-504 Coimbra, Portugal
>>>> Tel:+351.239 989 100 Fax:+351.239 989 119
>>>> http://www.criticalsoftware.com <http://www.criticalsoftware.com/>
>>>> jose-r-simoes@criticalsoftware.com 
>>>> <mailto:jose-r-simoes%40criticalsoftware.com>
>>>>
>>>>
>>>>
>>>>
>>>> Alberto Massari wrote:
>>>>> Hi Jose,
>>>>> what is the value of the str_url variable on the two platforms?
>>>>>
>>>>> Alberto
>>>>>
>>>>> At 11.53 23/05/2007 +0100, José Rui Simões wrote:
>>>>>> Dear all,
>>>>>>
>>>>>> I have a problem that has been annoying me for the last few days.
>>>>>>
>>>>>> I am building a test framework. Our test cases are created in an 
>>>>>> xml file which depicts the test case, since some settings are 
>>>>>> common to all the test cases we have a dtd file with these 
>>>>>> settings. My problem is that the xml and dtd files are correctly 
>>>>>> parsed in Ubuntu 7.04 but aren't in MS Windows.
>>>>>>
>>>>>> XML file:
>>>>>>
>>>>>> <?xml version = "1.0" encoding = "UTF-8"?>
>>>>>> <!DOCTYPE execution [
>>>>>>    <!-- settings -->
>>>>>>    <!ENTITY % settings SYSTEM "settings.dtd">
>>>>>>    %settings;
>>>>>> ]>
>>>>>>
>>>>>> <execution>
>>>>>>    <outputfiles deleteprevious="true"></outputfiles>
>>>>>>    <testmanager>
>>>>>>
>>>>>>    <outputter class="CAggregOutputter" create="true" level="20" 
>>>>>> name="agregoutputter" >
>>>>>>            <outputter class="CConsoleOutputter" create="true" 
>>>>>> level="20" name="consoleoutputter" />
>>>>>>            <outputter class="CBufferedFileOutputter" 
>>>>>> create="true" level="20" name="bufferedfileoutputter" />
>>>>>>        </outputter>
>>>>>>
>>>>>>        <!--&defaultuserinteraction;-->
>>>>>>        <userinteraction waittoend="true" rank="0" 
>>>>>> attachdebugger="false" />
>>>>>>        <exception handlesystem="true" />
>>>>>>
>>>>>>        <resultmanager class="CMsgCreatorResultManager" 
>>>>>> create="true" name="resultmanager">
>>>>>>            <xmlfile>./result-test-msg-id.xml</xmlfile>
>>>>>>        </resultmanager>
>>>>>>
>>>>>>        <thread name="default" create="true">
>>>>>>
>>>>>>        <scheduler class="CSchedulerStepInterleaving" 
>>>>>> create="true" name="scheduler" />
>>>>>>
>>>>>>            <syncgroup class="CMsgCreatorSyncGroup" create="true" 
>>>>>> name="test_msg_id">
>>>>>>
>>>>>>                <resourcepool class="CRCP_Integer" create="true" 
>>>>>> name="msg-id">
>>>>>>                    <range begin="0" end="6" step="1" />
>>>>>>                </resourcepool>
>>>>>>
>>>>>>                <resourcepool class="CRCP_Integer" create="true" 
>>>>>> name="msg-destination">
>>>>>>                    <range begin="0" end="128" step="32" />
>>>>>>                </resourcepool>
>>>>>>
>>>>>>                <resourcepool class="CRCP_String" create="true" 
>>>>>> name="name_of_tester">
>>>>>>                    <resource class="CRSC_String" create="true" 
>>>>>> name="user login"></resource>
>>>>>>                </resourcepool>
>>>>>>
>>>>>>                <resourcepool class="CRCP_String" create="true" 
>>>>>> name="name_of_tag">
>>>>>>                    <resource class="CRSC_String" create="true" 
>>>>>> name="cvs tag"></resource>
>>>>>>                </resourcepool>
>>>>>>
>>>>>>                <test class="CTestMsgID" create="true" 
>>>>>> name="TestMsgID">
>>>>>>                    <skipto iteration="0"/>
>>>>>>                </test>
>>>>>>
>>>>>>            </syncgroup>
>>>>>>
>>>>>>        </thread>
>>>>>>
>>>>>>    <run times="1" />
>>>>>>
>>>>>>    </testmanager>
>>>>>>
>>>>>> </execution>
>>>>>>
>>>>>>
>>>>>> DTD file:
>>>>>>
>>>>>> <!ENTITY outputLvl "20">
>>>>>> <!ENTITY name_of_tester "user login">
>>>>>> <!ENTITY name_of_tag "cvs tag">
>>>>>> <!ENTITY defaultuserinteraction '<userinteraction 
>>>>>> waittoend="true" rank="0" attachdebugger="false" />'>
>>>>>> <!ENTITY defaultexception '<exception handlesystem="true" />'>
>>>>>>
>>>>>> the parsing is done using the following code
>>>>>>
>>>>>> The code where it the problem occurs is this section.
>>>>>> CODE:
>>>>>>
>>>>>>    XMLPlatformUtils::Initialize();
>>>>>>    m_pcXMLParser = new XercesDOMParser ();
>>>>>>
>>>>>>    m_strURL = str_url;
>>>>>>
>>>>>>    m_pcXMLParser->setCreateEntityReferenceNodes(false);
>>>>>>
>>>>>>    // If we have an URL create an input source:
>>>>>>    if (!m_strURL.empty ()) {
>>>>>>        m_pcInputSource = new URLInputSource (XMLURL 
>>>>>> (m_strURL.c_str ()));
>>>>>>
>>>>>>        m_pcXMLParser->parse (*m_pcInputSource);
>>>>>>
>>>>>>
>>>>>>        if (m_pcXMLParser->getDocument () == NULL)
>>>>>>            throw TESTEXCEPTION("Found empty xml document. 
>>>>>> Possibly tried to open wrong document(see the next files: 
>>>>>> setings.dtd,..).");
>>>>>>
>>>>>>        if (m_pcXMLParser->getDocument ()->getDocumentElement () 
>>>>>> == NULL)
>>>>>>            throw TESTEXCEPTION("Found empty xml document. 
>>>>>> Possibly tried to open wrong document(see the next files: 
>>>>>> setings.dtd,..).");
>>>>>>
>>>>>>    } else
>>>>>>        m_pcInputSource = NULL;
>>>>>>
>>>>>>
>>>>>> In Windows it always returns null in the 
>>>>>> "m_pcXMLParser->getDocument ()->getDocumentElement ()" line. I 
>>>>>> have noticed that if I remove the "%settings" line in the XML 
>>>>>> file it does not return null but it also doesn't import the 
>>>>>> settings, so no use for this solution.
>>>>>>
>>>>>> I have been searching google and the user mailing list for 
>>>>>> something similar but couldn't find anything. One more thing I'm 
>>>>>> using the static version of Xerces-C 2.7 library.
>>>>>>
>>>>>> Hope you can help me, any more info you need please ask.
>>>>>>
>>>>>> Thanks in advance.
>>>>>>
>>>>>> Kind Regards
>>>>>>
>>>>>> -- 
>>>>>>
>>>>>> José Rui Simões
>>>>>>
>>>>>> Junior Engineer
>>>>>>
>>>>>> Critical Software, SA
>>>>>>
>>>>>> Parque Industrial de Taveiro, Lote 48
>>>>>> 3045-504 Coimbra, Portugal
>>>>>> Tel:+351.239 989 100 Fax:+351.239 989 119
>>>>>> http://www.criticalsoftware.com <http://www.criticalsoftware.com/>
>>>>>> jose-r-simoes@criticalsoftware.com 
>>>>>> <mailto:jose-r-simoes%40criticalsoftware.com>
>>>
>
>

Re: Problem importing dtd settings file in MS Windows

Posted by Alberto Massari <am...@datadirect.com>.
Jose,
you will have problems using those URLs: try 
using 
file:///d:/Cvsroot/critical/rd-defense/implementation/testframework/msg-creator-tfw/xml/run_test_msg_id.xml, 
or use a LocalFileInputSource with the 
d:\Cvsroot\critical\rd-defense\implementation\testframework\msg-creator-tfw\xml\run_test_msg_id.xml 
instead of a URLInputSource

Alberto

At 14.47 23/05/2007 +0100, José Rui Simões wrote:
>Hi Alberto,
>
>in Windows the str_url string has the following value:
>
>file:d:\Cvsroot\critical\rd-defense\implementation\testframework\msg-creator-tfw\xml\run_test_msg_id.xml
>
>in Linux it has the following value:
>
>file:/home/jr-simoes/Projects/msg-creator-tfw/core/../xml/run_test_msg_id.xml
>
>These are essentially the same path so the problem isn't here.
>
>Do you have any more suggestions.
>
>Kind Regards.
>
>José Rui Simões
>
>Junior Engineer
>
>Critical Software, SA
>
>Parque Industrial de Taveiro, Lote 48
>3045-504 Coimbra, Portugal
>Tel:+351.239 989 100 Fax:+351.239 989 119
>http://www.criticalsoftware.com <http://www.criticalsoftware.com/>
>jose-r-simoes@criticalsoftware.com 
><mailto:jose-r-simoes%40criticalsoftware.com>
>
>
>
>
>Alberto Massari wrote:
>>At 13.41 23/05/2007 +0100, José Rui Simões wrote:
>>>Do you mean the "settings.dtd" part next to 
>>>the SYSTEM keyword in the Entity declaration?
>>
>>No, I mean the str_url that's used to 
>>initialize the URLInputSource of the XML file:
>>
>>    m_strURL = str_url;
>>
>>    m_pcXMLParser->setCreateEntityReferenceNodes(false);
>>
>>    // If we have an URL create an input source:
>>    if (!m_strURL.empty ()) {
>>        m_pcInputSource = new URLInputSource (XMLURL (m_strURL.c_str ()));
>>
>>Because that is the base URL used to resolve 
>>the settings.dtd, and it could be the cause of the 'DTD file not found' error.
>>
>>Alberto
>>
>>
>>>if that's it it's the same the folder scheme is the same.
>>>
>>>Folder layout:
>>>
>>>main folder\
>>>    core code\
>>>    some helpers\
>>>    xml and dtd files\
>>>
>>>José Rui Simões
>>>
>>>Junior Engineer
>>>
>>>Critical Software, SA
>>>
>>>Parque Industrial de Taveiro, Lote 48
>>>3045-504 Coimbra, Portugal
>>>Tel:+351.239 989 100 Fax:+351.239 989 119
>>>http://www.criticalsoftware.com <http://www.criticalsoftware.com/>
>>>jose-r-simoes@criticalsoftware.com 
>>><mailto:jose-r-simoes%40criticalsoftware.com>
>>>
>>>
>>>
>>>
>>>Alberto Massari wrote:
>>>>Hi Jose,
>>>>what is the value of the str_url variable on the two platforms?
>>>>
>>>>Alberto
>>>>
>>>>At 11.53 23/05/2007 +0100, José Rui Simões wrote:
>>>>>Dear all,
>>>>>
>>>>>I have a problem that has been annoying me for the last few days.
>>>>>
>>>>>I am building a test framework. Our test 
>>>>>cases are created in an xml file which 
>>>>>depicts the test case, since some settings 
>>>>>are common to all the test cases we have a 
>>>>>dtd file with these settings. My problem is 
>>>>>that the xml and dtd files are correctly 
>>>>>parsed in Ubuntu 7.04 but aren't in MS Windows.
>>>>>
>>>>>XML file:
>>>>>
>>>>><?xml version = "1.0" encoding = "UTF-8"?>
>>>>><!DOCTYPE execution [
>>>>>    <!-- settings -->
>>>>>    <!ENTITY % settings SYSTEM "settings.dtd">
>>>>>    %settings;
>>>>>]>
>>>>>
>>>>><execution>
>>>>>    <outputfiles deleteprevious="true"></outputfiles>
>>>>>    <testmanager>
>>>>>
>>>>>    <outputter class="CAggregOutputter" 
>>>>> create="true" level="20" name="agregoutputter" >
>>>>>            <outputter 
>>>>> class="CConsoleOutputter" create="true" level="20" name="consoleoutputter" />
>>>>>            <outputter 
>>>>> class="CBufferedFileOutputter" 
>>>>> create="true" level="20" name="bufferedfileoutputter" />
>>>>>        </outputter>
>>>>>
>>>>>        <!--&defaultuserinteraction;-->
>>>>>        <userinteraction waittoend="true" 
>>>>> rank="0" attachdebugger="false" />
>>>>>        <exception handlesystem="true" />
>>>>>
>>>>>        <resultmanager 
>>>>> class="CMsgCreatorResultManager" create="true" name="resultmanager">
>>>>>            <xmlfile>./result-test-msg-id.xml</xmlfile>
>>>>>        </resultmanager>
>>>>>
>>>>>        <thread name="default" create="true">
>>>>>
>>>>>        <scheduler 
>>>>> class="CSchedulerStepInterleaving" create="true" name="scheduler" />
>>>>>
>>>>>            <syncgroup 
>>>>> class="CMsgCreatorSyncGroup" create="true" name="test_msg_id">
>>>>>
>>>>>                <resourcepool 
>>>>> class="CRCP_Integer" create="true" name="msg-id">
>>>>>                    <range begin="0" end="6" step="1" />
>>>>>                </resourcepool>
>>>>>
>>>>>                <resourcepool 
>>>>> class="CRCP_Integer" create="true" name="msg-destination">
>>>>>                    <range begin="0" end="128" step="32" />
>>>>>                </resourcepool>
>>>>>
>>>>>                <resourcepool 
>>>>> class="CRCP_String" create="true" name="name_of_tester">
>>>>>                    <resource 
>>>>> class="CRSC_String" create="true" name="user login"></resource>
>>>>>                </resourcepool>
>>>>>
>>>>>                <resourcepool 
>>>>> class="CRCP_String" create="true" name="name_of_tag">
>>>>>                    <resource 
>>>>> class="CRSC_String" create="true" name="cvs tag"></resource>
>>>>>                </resourcepool>
>>>>>
>>>>>                <test class="CTestMsgID" create="true" name="TestMsgID">
>>>>>                    <skipto iteration="0"/>
>>>>>                </test>
>>>>>
>>>>>            </syncgroup>
>>>>>
>>>>>        </thread>
>>>>>
>>>>>    <run times="1" />
>>>>>
>>>>>    </testmanager>
>>>>>
>>>>></execution>
>>>>>
>>>>>
>>>>>DTD file:
>>>>>
>>>>><!ENTITY outputLvl "20">
>>>>><!ENTITY name_of_tester "user login">
>>>>><!ENTITY name_of_tag "cvs tag">
>>>>><!ENTITY defaultuserinteraction 
>>>>>'<userinteraction waittoend="true" rank="0" attachdebugger="false" />'>
>>>>><!ENTITY defaultexception '<exception handlesystem="true" />'>
>>>>>
>>>>>the parsing is done using the following code
>>>>>
>>>>>The code where it the problem occurs is this section.
>>>>>CODE:
>>>>>
>>>>>    XMLPlatformUtils::Initialize();
>>>>>    m_pcXMLParser = new XercesDOMParser ();
>>>>>
>>>>>    m_strURL = str_url;
>>>>>
>>>>>    m_pcXMLParser->setCreateEntityReferenceNodes(false);
>>>>>
>>>>>    // If we have an URL create an input source:
>>>>>    if (!m_strURL.empty ()) {
>>>>>        m_pcInputSource = new URLInputSource (XMLURL (m_strURL.c_str ()));
>>>>>
>>>>>        m_pcXMLParser->parse (*m_pcInputSource);
>>>>>
>>>>>
>>>>>        if (m_pcXMLParser->getDocument () == NULL)
>>>>>            throw TESTEXCEPTION("Found empty 
>>>>> xml document. Possibly tried to open wrong 
>>>>> document(see the next files: setings.dtd,..).");
>>>>>
>>>>>        if (m_pcXMLParser->getDocument ()->getDocumentElement () == NULL)
>>>>>            throw TESTEXCEPTION("Found empty 
>>>>> xml document. Possibly tried to open wrong 
>>>>> document(see the next files: setings.dtd,..).");
>>>>>
>>>>>    } else
>>>>>        m_pcInputSource = NULL;
>>>>>
>>>>>
>>>>>In Windows it always returns null in the 
>>>>>"m_pcXMLParser->getDocument 
>>>>>()->getDocumentElement ()" line. I have 
>>>>>noticed that if I remove the "%settings" 
>>>>>line in the XML file it does not return null 
>>>>>but it also doesn't import the settings, so no use for this solution.
>>>>>
>>>>>I have been searching google and the user 
>>>>>mailing list for something similar but 
>>>>>couldn't find anything. One more thing I'm 
>>>>>using the static version of Xerces-C 2.7 library.
>>>>>
>>>>>Hope you can help me, any more info you need please ask.
>>>>>
>>>>>Thanks in advance.
>>>>>
>>>>>Kind Regards
>>>>>
>>>>>--
>>>>>
>>>>>José Rui Simões
>>>>>
>>>>>Junior Engineer
>>>>>
>>>>>Critical Software, SA
>>>>>
>>>>>Parque Industrial de Taveiro, Lote 48
>>>>>3045-504 Coimbra, Portugal
>>>>>Tel:+351.239 989 100 Fax:+351.239 989 119
>>>>>http://www.criticalsoftware.com <http://www.criticalsoftware.com/>
>>>>>jose-r-simoes@criticalsoftware.com 
>>>>><mailto:jose-r-simoes%40criticalsoftware.com>
>>


Re: Problem importing dtd settings file in MS Windows

Posted by José Rui Simões <jo...@criticalsoftware.com>.
Hi Alberto,

in Windows the str_url string has the following value:
    
file:d:\Cvsroot\critical\rd-defense\implementation\testframework\msg-creator-tfw\xml\run_test_msg_id.xml

in Linux it has the following value:
    
file:/home/jr-simoes/Projects/msg-creator-tfw/core/../xml/run_test_msg_id.xml 


These are essentially the same path so the problem isn't here.

Do you have any more suggestions.

Kind Regards.

José Rui Simões

Junior Engineer

Critical Software, SA

Parque Industrial de Taveiro, Lote 48
3045-504 Coimbra, Portugal
Tel:+351.239 989 100 Fax:+351.239 989 119
http://www.criticalsoftware.com <http://www.criticalsoftware.com/>
jose-r-simoes@criticalsoftware.com 
<mailto:jose-r-simoes%40criticalsoftware.com>




Alberto Massari wrote:
> At 13.41 23/05/2007 +0100, José Rui Simões wrote:
>> Do you mean the "settings.dtd" part next to the SYSTEM keyword in the 
>> Entity declaration?
>
> No, I mean the str_url that's used to initialize the URLInputSource of 
> the XML file:
>
>    m_strURL = str_url;
>
>    m_pcXMLParser->setCreateEntityReferenceNodes(false);
>
>    // If we have an URL create an input source:
>    if (!m_strURL.empty ()) {
>        m_pcInputSource = new URLInputSource (XMLURL (m_strURL.c_str ()));
>
> Because that is the base URL used to resolve the settings.dtd, and it 
> could be the cause of the 'DTD file not found' error.
>
> Alberto
>
>
>> if that's it it's the same the folder scheme is the same.
>>
>> Folder layout:
>>
>> main folder\
>>    core code\
>>    some helpers\
>>    xml and dtd files\
>>
>> José Rui Simões
>>
>> Junior Engineer
>>
>> Critical Software, SA
>>
>> Parque Industrial de Taveiro, Lote 48
>> 3045-504 Coimbra, Portugal
>> Tel:+351.239 989 100 Fax:+351.239 989 119
>> http://www.criticalsoftware.com <http://www.criticalsoftware.com/>
>> jose-r-simoes@criticalsoftware.com 
>> <mailto:jose-r-simoes%40criticalsoftware.com>
>>
>>
>>
>>
>> Alberto Massari wrote:
>>> Hi Jose,
>>> what is the value of the str_url variable on the two platforms?
>>>
>>> Alberto
>>>
>>> At 11.53 23/05/2007 +0100, José Rui Simões wrote:
>>>> Dear all,
>>>>
>>>> I have a problem that has been annoying me for the last few days.
>>>>
>>>> I am building a test framework. Our test cases are created in an 
>>>> xml file which depicts the test case, since some settings are 
>>>> common to all the test cases we have a dtd file with these 
>>>> settings. My problem is that the xml and dtd files are correctly 
>>>> parsed in Ubuntu 7.04 but aren't in MS Windows.
>>>>
>>>> XML file:
>>>>
>>>> <?xml version = "1.0" encoding = "UTF-8"?>
>>>> <!DOCTYPE execution [
>>>>    <!-- settings -->
>>>>    <!ENTITY % settings SYSTEM "settings.dtd">
>>>>    %settings;
>>>> ]>
>>>>
>>>> <execution>
>>>>    <outputfiles deleteprevious="true"></outputfiles>
>>>>    <testmanager>
>>>>
>>>>    <outputter class="CAggregOutputter" create="true" level="20" 
>>>> name="agregoutputter" >
>>>>            <outputter class="CConsoleOutputter" create="true" 
>>>> level="20" name="consoleoutputter" />
>>>>            <outputter class="CBufferedFileOutputter" create="true" 
>>>> level="20" name="bufferedfileoutputter" />
>>>>        </outputter>
>>>>
>>>>        <!--&defaultuserinteraction;-->
>>>>        <userinteraction waittoend="true" rank="0" 
>>>> attachdebugger="false" />
>>>>        <exception handlesystem="true" />
>>>>
>>>>        <resultmanager class="CMsgCreatorResultManager" 
>>>> create="true" name="resultmanager">
>>>>            <xmlfile>./result-test-msg-id.xml</xmlfile>
>>>>        </resultmanager>
>>>>
>>>>        <thread name="default" create="true">
>>>>
>>>>        <scheduler class="CSchedulerStepInterleaving" create="true" 
>>>> name="scheduler" />
>>>>
>>>>            <syncgroup class="CMsgCreatorSyncGroup" create="true" 
>>>> name="test_msg_id">
>>>>
>>>>                <resourcepool class="CRCP_Integer" create="true" 
>>>> name="msg-id">
>>>>                    <range begin="0" end="6" step="1" />
>>>>                </resourcepool>
>>>>
>>>>                <resourcepool class="CRCP_Integer" create="true" 
>>>> name="msg-destination">
>>>>                    <range begin="0" end="128" step="32" />
>>>>                </resourcepool>
>>>>
>>>>                <resourcepool class="CRCP_String" create="true" 
>>>> name="name_of_tester">
>>>>                    <resource class="CRSC_String" create="true" 
>>>> name="user login"></resource>
>>>>                </resourcepool>
>>>>
>>>>                <resourcepool class="CRCP_String" create="true" 
>>>> name="name_of_tag">
>>>>                    <resource class="CRSC_String" create="true" 
>>>> name="cvs tag"></resource>
>>>>                </resourcepool>
>>>>
>>>>                <test class="CTestMsgID" create="true" 
>>>> name="TestMsgID">
>>>>                    <skipto iteration="0"/>
>>>>                </test>
>>>>
>>>>            </syncgroup>
>>>>
>>>>        </thread>
>>>>
>>>>    <run times="1" />
>>>>
>>>>    </testmanager>
>>>>
>>>> </execution>
>>>>
>>>>
>>>> DTD file:
>>>>
>>>> <!ENTITY outputLvl "20">
>>>> <!ENTITY name_of_tester "user login">
>>>> <!ENTITY name_of_tag "cvs tag">
>>>> <!ENTITY defaultuserinteraction '<userinteraction waittoend="true" 
>>>> rank="0" attachdebugger="false" />'>
>>>> <!ENTITY defaultexception '<exception handlesystem="true" />'>
>>>>
>>>> the parsing is done using the following code
>>>>
>>>> The code where it the problem occurs is this section.
>>>> CODE:
>>>>
>>>>    XMLPlatformUtils::Initialize();
>>>>    m_pcXMLParser = new XercesDOMParser ();
>>>>
>>>>    m_strURL = str_url;
>>>>
>>>>    m_pcXMLParser->setCreateEntityReferenceNodes(false);
>>>>
>>>>    // If we have an URL create an input source:
>>>>    if (!m_strURL.empty ()) {
>>>>        m_pcInputSource = new URLInputSource (XMLURL (m_strURL.c_str 
>>>> ()));
>>>>
>>>>        m_pcXMLParser->parse (*m_pcInputSource);
>>>>
>>>>
>>>>        if (m_pcXMLParser->getDocument () == NULL)
>>>>            throw TESTEXCEPTION("Found empty xml document. Possibly 
>>>> tried to open wrong document(see the next files: setings.dtd,..).");
>>>>
>>>>        if (m_pcXMLParser->getDocument ()->getDocumentElement () == 
>>>> NULL)
>>>>            throw TESTEXCEPTION("Found empty xml document. Possibly 
>>>> tried to open wrong document(see the next files: setings.dtd,..).");
>>>>
>>>>    } else
>>>>        m_pcInputSource = NULL;
>>>>
>>>>
>>>> In Windows it always returns null in the 
>>>> "m_pcXMLParser->getDocument ()->getDocumentElement ()" line. I have 
>>>> noticed that if I remove the "%settings" line in the XML file it 
>>>> does not return null but it also doesn't import the settings, so no 
>>>> use for this solution.
>>>>
>>>> I have been searching google and the user mailing list for 
>>>> something similar but couldn't find anything. One more thing I'm 
>>>> using the static version of Xerces-C 2.7 library.
>>>>
>>>> Hope you can help me, any more info you need please ask.
>>>>
>>>> Thanks in advance.
>>>>
>>>> Kind Regards
>>>>
>>>> -- 
>>>>
>>>> José Rui Simões
>>>>
>>>> Junior Engineer
>>>>
>>>> Critical Software, SA
>>>>
>>>> Parque Industrial de Taveiro, Lote 48
>>>> 3045-504 Coimbra, Portugal
>>>> Tel:+351.239 989 100 Fax:+351.239 989 119
>>>> http://www.criticalsoftware.com <http://www.criticalsoftware.com/>
>>>> jose-r-simoes@criticalsoftware.com 
>>>> <mailto:jose-r-simoes%40criticalsoftware.com>
>>>>
>>>
>
>

Re: Problem importing dtd settings file in MS Windows

Posted by Alberto Massari <am...@datadirect.com>.
At 13.41 23/05/2007 +0100, José Rui Simões wrote:
>Do you mean the "settings.dtd" part next to the 
>SYSTEM keyword in the Entity declaration?

No, I mean the str_url that's used to initialize 
the URLInputSource of the XML file:

    m_strURL = str_url;

    m_pcXMLParser->setCreateEntityReferenceNodes(false);

    // If we have an URL create an input source:
    if (!m_strURL.empty ()) {
        m_pcInputSource = new URLInputSource (XMLURL (m_strURL.c_str ()));

Because that is the base URL used to resolve the 
settings.dtd, and it could be the cause of the 'DTD file not found' error.

Alberto


>if that's it it's the same the folder scheme is the same.
>
>Folder layout:
>
>main folder\
>    core code\
>    some helpers\
>    xml and dtd files\
>
>José Rui Simões
>
>Junior Engineer
>
>Critical Software, SA
>
>Parque Industrial de Taveiro, Lote 48
>3045-504 Coimbra, Portugal
>Tel:+351.239 989 100 Fax:+351.239 989 119
>http://www.criticalsoftware.com <http://www.criticalsoftware.com/>
>jose-r-simoes@criticalsoftware.com 
><mailto:jose-r-simoes%40criticalsoftware.com>
>
>
>
>
>Alberto Massari wrote:
>>Hi Jose,
>>what is the value of the str_url variable on the two platforms?
>>
>>Alberto
>>
>>At 11.53 23/05/2007 +0100, José Rui Simões wrote:
>>>Dear all,
>>>
>>>I have a problem that has been annoying me for the last few days.
>>>
>>>I am building a test framework. Our test cases 
>>>are created in an xml file which depicts the 
>>>test case, since some settings are common to 
>>>all the test cases we have a dtd file with 
>>>these settings. My problem is that the xml and 
>>>dtd files are correctly parsed in Ubuntu 7.04 but aren't in MS Windows.
>>>
>>>XML file:
>>>
>>><?xml version = "1.0" encoding = "UTF-8"?>
>>><!DOCTYPE execution [
>>>    <!-- settings -->
>>>    <!ENTITY % settings SYSTEM "settings.dtd">
>>>    %settings;
>>>]>
>>>
>>><execution>
>>>    <outputfiles deleteprevious="true"></outputfiles>
>>>    <testmanager>
>>>
>>>    <outputter class="CAggregOutputter" 
>>> create="true" level="20" name="agregoutputter" >
>>>            <outputter 
>>> class="CConsoleOutputter" create="true" level="20" name="consoleoutputter" />
>>>            <outputter 
>>> class="CBufferedFileOutputter" create="true" 
>>> level="20" name="bufferedfileoutputter" />
>>>        </outputter>
>>>
>>>        <!--&defaultuserinteraction;-->
>>>        <userinteraction waittoend="true" rank="0" attachdebugger="false" />
>>>        <exception handlesystem="true" />
>>>
>>>        <resultmanager 
>>> class="CMsgCreatorResultManager" create="true" name="resultmanager">
>>>            <xmlfile>./result-test-msg-id.xml</xmlfile>
>>>        </resultmanager>
>>>
>>>        <thread name="default" create="true">
>>>
>>>        <scheduler 
>>> class="CSchedulerStepInterleaving" create="true" name="scheduler" />
>>>
>>>            <syncgroup 
>>> class="CMsgCreatorSyncGroup" create="true" name="test_msg_id">
>>>
>>>                <resourcepool 
>>> class="CRCP_Integer" create="true" name="msg-id">
>>>                    <range begin="0" end="6" step="1" />
>>>                </resourcepool>
>>>
>>>                <resourcepool 
>>> class="CRCP_Integer" create="true" name="msg-destination">
>>>                    <range begin="0" end="128" step="32" />
>>>                </resourcepool>
>>>
>>>                <resourcepool 
>>> class="CRCP_String" create="true" name="name_of_tester">
>>>                    <resource 
>>> class="CRSC_String" create="true" name="user login"></resource>
>>>                </resourcepool>
>>>
>>>                <resourcepool 
>>> class="CRCP_String" create="true" name="name_of_tag">
>>>                    <resource 
>>> class="CRSC_String" create="true" name="cvs tag"></resource>
>>>                </resourcepool>
>>>
>>>                <test class="CTestMsgID" create="true" name="TestMsgID">
>>>                    <skipto iteration="0"/>
>>>                </test>
>>>
>>>            </syncgroup>
>>>
>>>        </thread>
>>>
>>>    <run times="1" />
>>>
>>>    </testmanager>
>>>
>>></execution>
>>>
>>>
>>>DTD file:
>>>
>>><!ENTITY outputLvl "20">
>>><!ENTITY name_of_tester "user login">
>>><!ENTITY name_of_tag "cvs tag">
>>><!ENTITY defaultuserinteraction 
>>>'<userinteraction waittoend="true" rank="0" attachdebugger="false" />'>
>>><!ENTITY defaultexception '<exception handlesystem="true" />'>
>>>
>>>the parsing is done using the following code
>>>
>>>The code where it the problem occurs is this section.
>>>CODE:
>>>
>>>    XMLPlatformUtils::Initialize();
>>>    m_pcXMLParser = new XercesDOMParser ();
>>>
>>>    m_strURL = str_url;
>>>
>>>    m_pcXMLParser->setCreateEntityReferenceNodes(false);
>>>
>>>    // If we have an URL create an input source:
>>>    if (!m_strURL.empty ()) {
>>>        m_pcInputSource = new URLInputSource (XMLURL (m_strURL.c_str ()));
>>>
>>>        m_pcXMLParser->parse (*m_pcInputSource);
>>>
>>>
>>>        if (m_pcXMLParser->getDocument () == NULL)
>>>            throw TESTEXCEPTION("Found empty 
>>> xml document. Possibly tried to open wrong 
>>> document(see the next files: setings.dtd,..).");
>>>
>>>        if (m_pcXMLParser->getDocument ()->getDocumentElement () == NULL)
>>>            throw TESTEXCEPTION("Found empty 
>>> xml document. Possibly tried to open wrong 
>>> document(see the next files: setings.dtd,..).");
>>>
>>>    } else
>>>        m_pcInputSource = NULL;
>>>
>>>
>>>In Windows it always returns null in the 
>>>"m_pcXMLParser->getDocument 
>>>()->getDocumentElement ()" line. I have 
>>>noticed that if I remove the "%settings" line 
>>>in the XML file it does not return null but it 
>>>also doesn't import the settings, so no use for this solution.
>>>
>>>I have been searching google and the user 
>>>mailing list for something similar but 
>>>couldn't find anything. One more thing I'm 
>>>using the static version of Xerces-C 2.7 library.
>>>
>>>Hope you can help me, any more info you need please ask.
>>>
>>>Thanks in advance.
>>>
>>>Kind Regards
>>>
>>>--
>>>
>>>José Rui Simões
>>>
>>>Junior Engineer
>>>
>>>Critical Software, SA
>>>
>>>Parque Industrial de Taveiro, Lote 48
>>>3045-504 Coimbra, Portugal
>>>Tel:+351.239 989 100 Fax:+351.239 989 119
>>>http://www.criticalsoftware.com <http://www.criticalsoftware.com/>
>>>jose-r-simoes@criticalsoftware.com 
>>><mailto:jose-r-simoes%40criticalsoftware.com>
>>>
>>


Re: Problem importing dtd settings file in MS Windows

Posted by José Rui Simões <jo...@criticalsoftware.com>.
Do you mean the "settings.dtd" part next to the SYSTEM keyword in the 
Entity declaration?

if that's it it's the same the folder scheme is the same.

Folder layout:

main folder\
    core code\
    some helpers\
    xml and dtd files\

José Rui Simões

Junior Engineer

Critical Software, SA

Parque Industrial de Taveiro, Lote 48
3045-504 Coimbra, Portugal
Tel:+351.239 989 100 Fax:+351.239 989 119
http://www.criticalsoftware.com <http://www.criticalsoftware.com/>
jose-r-simoes@criticalsoftware.com 
<mailto:jose-r-simoes%40criticalsoftware.com>




Alberto Massari wrote:
> Hi Jose,
> what is the value of the str_url variable on the two platforms?
>
> Alberto
>
> At 11.53 23/05/2007 +0100, José Rui Simões wrote:
>> Dear all,
>>
>> I have a problem that has been annoying me for the last few days.
>>
>> I am building a test framework. Our test cases are created in an xml 
>> file which depicts the test case, since some settings are common to 
>> all the test cases we have a dtd file with these settings. My problem 
>> is that the xml and dtd files are correctly parsed in Ubuntu 7.04 but 
>> aren't in MS Windows.
>>
>> XML file:
>>
>> <?xml version = "1.0" encoding = "UTF-8"?>
>> <!DOCTYPE execution [
>>    <!-- settings -->
>>    <!ENTITY % settings SYSTEM "settings.dtd">
>>    %settings;
>> ]>
>>
>> <execution>
>>    <outputfiles deleteprevious="true"></outputfiles>
>>    <testmanager>
>>
>>    <outputter class="CAggregOutputter" create="true" level="20" 
>> name="agregoutputter" >
>>            <outputter class="CConsoleOutputter" create="true" 
>> level="20" name="consoleoutputter" />
>>            <outputter class="CBufferedFileOutputter" create="true" 
>> level="20" name="bufferedfileoutputter" />
>>        </outputter>
>>
>>        <!--&defaultuserinteraction;-->
>>        <userinteraction waittoend="true" rank="0" 
>> attachdebugger="false" />
>>        <exception handlesystem="true" />
>>
>>        <resultmanager class="CMsgCreatorResultManager" create="true" 
>> name="resultmanager">
>>            <xmlfile>./result-test-msg-id.xml</xmlfile>
>>        </resultmanager>
>>
>>        <thread name="default" create="true">
>>
>>        <scheduler class="CSchedulerStepInterleaving" create="true" 
>> name="scheduler" />
>>
>>            <syncgroup class="CMsgCreatorSyncGroup" create="true" 
>> name="test_msg_id">
>>
>>                <resourcepool class="CRCP_Integer" create="true" 
>> name="msg-id">
>>                    <range begin="0" end="6" step="1" />
>>                </resourcepool>
>>
>>                <resourcepool class="CRCP_Integer" create="true" 
>> name="msg-destination">
>>                    <range begin="0" end="128" step="32" />
>>                </resourcepool>
>>
>>                <resourcepool class="CRCP_String" create="true" 
>> name="name_of_tester">
>>                    <resource class="CRSC_String" create="true" 
>> name="user login"></resource>
>>                </resourcepool>
>>
>>                <resourcepool class="CRCP_String" create="true" 
>> name="name_of_tag">
>>                    <resource class="CRSC_String" create="true" 
>> name="cvs tag"></resource>
>>                </resourcepool>
>>
>>                <test class="CTestMsgID" create="true" name="TestMsgID">
>>                    <skipto iteration="0"/>
>>                </test>
>>
>>            </syncgroup>
>>
>>        </thread>
>>
>>    <run times="1" />
>>
>>    </testmanager>
>>
>> </execution>
>>
>>
>> DTD file:
>>
>> <!ENTITY outputLvl "20">
>> <!ENTITY name_of_tester "user login">
>> <!ENTITY name_of_tag "cvs tag">
>> <!ENTITY defaultuserinteraction '<userinteraction waittoend="true" 
>> rank="0" attachdebugger="false" />'>
>> <!ENTITY defaultexception '<exception handlesystem="true" />'>
>>
>> the parsing is done using the following code
>>
>> The code where it the problem occurs is this section.
>> CODE:
>>
>>    XMLPlatformUtils::Initialize();
>>    m_pcXMLParser = new XercesDOMParser ();
>>
>>    m_strURL = str_url;
>>
>>    m_pcXMLParser->setCreateEntityReferenceNodes(false);
>>
>>    // If we have an URL create an input source:
>>    if (!m_strURL.empty ()) {
>>        m_pcInputSource = new URLInputSource (XMLURL (m_strURL.c_str 
>> ()));
>>
>>        m_pcXMLParser->parse (*m_pcInputSource);
>>
>>
>>        if (m_pcXMLParser->getDocument () == NULL)
>>            throw TESTEXCEPTION("Found empty xml document. Possibly 
>> tried to open wrong document(see the next files: setings.dtd,..).");
>>
>>        if (m_pcXMLParser->getDocument ()->getDocumentElement () == NULL)
>>            throw TESTEXCEPTION("Found empty xml document. Possibly 
>> tried to open wrong document(see the next files: setings.dtd,..).");
>>
>>    } else
>>        m_pcInputSource = NULL;
>>
>>
>> In Windows it always returns null in the "m_pcXMLParser->getDocument 
>> ()->getDocumentElement ()" line. I have noticed that if I remove the 
>> "%settings" line in the XML file it does not return null but it also 
>> doesn't import the settings, so no use for this solution.
>>
>> I have been searching google and the user mailing list for something 
>> similar but couldn't find anything. One more thing I'm using the 
>> static version of Xerces-C 2.7 library.
>>
>> Hope you can help me, any more info you need please ask.
>>
>> Thanks in advance.
>>
>> Kind Regards
>>
>> -- 
>>
>> José Rui Simões
>>
>> Junior Engineer
>>
>> Critical Software, SA
>>
>> Parque Industrial de Taveiro, Lote 48
>> 3045-504 Coimbra, Portugal
>> Tel:+351.239 989 100 Fax:+351.239 989 119
>> http://www.criticalsoftware.com <http://www.criticalsoftware.com/>
>> jose-r-simoes@criticalsoftware.com 
>> <mailto:jose-r-simoes%40criticalsoftware.com>
>>
>>
>
>

Re: Problem importing dtd settings file in MS Windows

Posted by Alberto Massari <am...@datadirect.com>.
Hi Jose,
what is the value of the str_url variable on the two platforms?

Alberto

At 11.53 23/05/2007 +0100, José Rui Simões wrote:
>Dear all,
>
>I have a problem that has been annoying me for the last few days.
>
>I am building a test framework. Our test cases 
>are created in an xml file which depicts the 
>test case, since some settings are common to all 
>the test cases we have a dtd file with these 
>settings. My problem is that the xml and dtd 
>files are correctly parsed in Ubuntu 7.04 but aren't in MS Windows.
>
>XML file:
>
><?xml version = "1.0" encoding = "UTF-8"?>
><!DOCTYPE execution [
>    <!-- settings -->
>    <!ENTITY % settings SYSTEM "settings.dtd">
>    %settings;
>]>
>
><execution>
>    <outputfiles deleteprevious="true"></outputfiles>
>    <testmanager>
>
>    <outputter class="CAggregOutputter" 
> create="true" level="20" name="agregoutputter" >
>            <outputter class="CConsoleOutputter" 
> create="true" level="20" name="consoleoutputter" />
>            <outputter 
> class="CBufferedFileOutputter" create="true" 
> level="20" name="bufferedfileoutputter" />
>        </outputter>
>
>        <!--&defaultuserinteraction;-->
>        <userinteraction waittoend="true" rank="0" attachdebugger="false" />
>        <exception handlesystem="true" />
>
>        <resultmanager 
> class="CMsgCreatorResultManager" create="true" name="resultmanager">
>            <xmlfile>./result-test-msg-id.xml</xmlfile>
>        </resultmanager>
>
>        <thread name="default" create="true">
>
>        <scheduler 
> class="CSchedulerStepInterleaving" create="true" name="scheduler" />
>
>            <syncgroup 
> class="CMsgCreatorSyncGroup" create="true" name="test_msg_id">
>
>                <resourcepool 
> class="CRCP_Integer" create="true" name="msg-id">
>                    <range begin="0" end="6" step="1" />
>                </resourcepool>
>
>                <resourcepool 
> class="CRCP_Integer" create="true" name="msg-destination">
>                    <range begin="0" end="128" step="32" />
>                </resourcepool>
>
>                <resourcepool 
> class="CRCP_String" create="true" name="name_of_tester">
>                    <resource 
> class="CRSC_String" create="true" name="user login"></resource>
>                </resourcepool>
>
>                <resourcepool 
> class="CRCP_String" create="true" name="name_of_tag">
>                    <resource 
> class="CRSC_String" create="true" name="cvs tag"></resource>
>                </resourcepool>
>
>                <test class="CTestMsgID" create="true" name="TestMsgID">
>                    <skipto iteration="0"/>
>                </test>
>
>            </syncgroup>
>
>        </thread>
>
>    <run times="1" />
>
>    </testmanager>
>
></execution>
>
>
>DTD file:
>
><!ENTITY outputLvl "20">
><!ENTITY name_of_tester "user login">
><!ENTITY name_of_tag "cvs tag">
><!ENTITY defaultuserinteraction 
>'<userinteraction waittoend="true" rank="0" attachdebugger="false" />'>
><!ENTITY defaultexception '<exception handlesystem="true" />'>
>
>the parsing is done using the following code
>
>The code where it the problem occurs is this section.
>CODE:
>
>    XMLPlatformUtils::Initialize();
>    m_pcXMLParser = new XercesDOMParser ();
>
>    m_strURL = str_url;
>
>    m_pcXMLParser->setCreateEntityReferenceNodes(false);
>
>    // If we have an URL create an input source:
>    if (!m_strURL.empty ()) {
>        m_pcInputSource = new URLInputSource (XMLURL (m_strURL.c_str ()));
>
>        m_pcXMLParser->parse (*m_pcInputSource);
>
>
>        if (m_pcXMLParser->getDocument () == NULL)
>            throw TESTEXCEPTION("Found empty xml 
> document. Possibly tried to open wrong 
> document(see the next files: setings.dtd,..).");
>
>        if (m_pcXMLParser->getDocument ()->getDocumentElement () == NULL)
>            throw TESTEXCEPTION("Found empty xml 
> document. Possibly tried to open wrong 
> document(see the next files: setings.dtd,..).");
>
>    } else
>        m_pcInputSource = NULL;
>
>
>In Windows it always returns null in the 
>"m_pcXMLParser->getDocument 
>()->getDocumentElement ()" line. I have noticed 
>that if I remove the "%settings" line in the XML 
>file it does not return null but it also doesn't 
>import the settings, so no use for this solution.
>
>I have been searching google and the user 
>mailing list for something similar but couldn't 
>find anything. One more thing I'm using the 
>static version of Xerces-C 2.7 library.
>
>Hope you can help me, any more info you need please ask.
>
>Thanks in advance.
>
>Kind Regards
>
>--
>
>José Rui Simões
>
>Junior Engineer
>
>Critical Software, SA
>
>Parque Industrial de Taveiro, Lote 48
>3045-504 Coimbra, Portugal
>Tel:+351.239 989 100 Fax:+351.239 989 119
>http://www.criticalsoftware.com <http://www.criticalsoftware.com/>
>jose-r-simoes@criticalsoftware.com 
><mailto:jose-r-simoes%40criticalsoftware.com>
>
>