[
https://issues.apache.org/jira/browse/LOGCXX-348?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Thorsten Schöning resolved LOGCXX-348.
--------------------------------------
Resolution: Cannot Reproduce
I could not reproduce this problem and therefore will close the bug. Sounds
more like a usage error to me, something like missing files or such.
> DOMConfigurator configure method crashes with full path
> -------------------------------------------------------
>
> Key: LOGCXX-348
> URL: https://issues.apache.org/jira/browse/LOGCXX-348
> Project: Log4cxx
> Issue Type: Bug
> Components: Configurator
> Affects Versions: 0.10.0
> Environment: Windows Visual Studio 2005 on Windows XP SP2
> Reporter: Joseph Armbruster
> Assignee: Curt Arnold
>
> The DOMConfigurator does not appear to accept full-paths with the configure
> function. I do not know if this is by design or not but I thought it was a
> bug.
> I did one test using the xml filename alone as you see below. The xml file
> in this test was located in the current working directory. This call works.
> log4cxx::xml::DOMConfigurator::configure("log4cxx.xml");
> I did another test (the one that I would like to work) using the full path to
> the xml filename as follows. This call does not work.
> std::string fullPath = "c:/program files/myapp/log4cxx.xml";
> log4cxx::xml::DOMConfigurator::configure(fullPath);
> An exception was being thrown and I figured out why. The following function
> is what i'm calling into in DOMConfigurator.cpp:
> void DOMConfigurator::configure(const std::string& filename)
> {
> // String value of filename here: C:/Program Files/MyApp/log4cxx.xml
> File file(filename);
> // file.getPath().c_str() value here: C
> DOMConfigurator().doConfigure(file, LogManager::getLoggerRepository());
> }
> It appears the file object is truncating the path and hence the call to
> apr_open_file following in doConfigure is crashing.
> Is this by design?
--
This message was sent by Atlassian JIRA
(v6.1.5#6160)