logging-log4cxx-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Thorsten Schöning <tschoen...@am-soft.de>
Subject Re: exception std::out_of_range in StringHelper::startsWith
Date Sun, 17 Oct 2010 13:15:12 GMT
Guten Tag Jacob L. Anawalt,
am Freitag, 15. Oktober 2010 um 23:30 schrieben Sie:

> I'm not sure what this named root logger you're referring too. In xml
> config it's just <root> and in property format it's log4j.rootLogger.


I mean the logger which gets configured with "root".

> PQ
> PQ.Worker
> PQ.TX.Lookup

> I've been building with the GCC on Debian for a few years now without 
> any out_of_range errors to do with log4cxx loggers.

My configuration is similiar, I have the root logger and one main
logger of my own configured. The error occurs in startsWith with
variable s set to "root" and prefix set to "Dokliste". Regarding the
stack trace the problem seems to be while configuration, but I didn't
get it to reproduce with a more simple test program. The test program
works well, but this application, where I started, does always fail if
I uncomment my changes to startsWith.

I attached a screenshot of the Debugger if anyone is interested,
underneath is an extract my configuration. The screenshot shows the
contents of the two variables and the stack trace. Log4cxx is
configured using the following code:

+ "\\log4cxx.xml").c_str());
                static log4cxx::LoggerPtr logger = log4cxx::Logger::getLogger(L"Dokliste.Main");
                LOG4CXX_INFO(logger, L"Programmstart");

My test program, where the problem didn't occur, configures log4cxx
the same way. The logger Dokliste.Main existed in some of my test,
too, with may other loggers, but two loggers are enought to produce
the problem in the on application where it does occur.

<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE log4j:configuration>

<log4j:configuration xmlns:log4j="http://logging.apache.org/" debug="false" threshold="null">

        <appender       name="userSpecificLogFile"

                <level  value="TRACE"

                <appender-ref   ref="userSpecificLogFile"

        <logger name="Dokliste"
                <level  value="TRACE"

                <appender-ref   ref="userSpecificLogFile"


Mit freundlichen Grüßen,

Thorsten Schöning

Thorsten Schöning
AM-SoFT IT-Systeme - Hameln | Potsdam | Leipzig
Telefon: Potsdam: 0331-743881-0
E-Mail:  tschoening@am-soft.de
Web:     http://www.am-soft.de

AM-SoFT GmbH IT-Systeme, Konsumhof 1-5, 14482 Potsdam
Amtsgericht Potsdam HRB 21278 P, Geschäftsführer: Andreas Muchow
View raw message