swebb2066 commented on a change in pull request #90:
URL: https://github.com/apache/logging-log4cxx/pull/90#discussion_r777147352



##########
File path: src/main/include/log4cxx/logger.h
##########
@@ -617,13 +617,13 @@ class LOG4CXX_EXPORT Logger :
 
                @throws RuntimeException if all levels are null in the hierarchy
                */
-               virtual const LevelPtr getEffectiveLevel() const;
+               virtual const LevelPtr& getEffectiveLevel() const;
 
                /**
                Return the the LoggerRepository where this
                <code>Logger</code> is attached.
                */
-               log4cxx::spi::LoggerRepositoryWeakPtr getLoggerRepository() 
const;
+               log4cxx::spi::LoggerRepository* getLoggerRepository() const;

Review comment:
       I will measure the impact with 'm->priv->repository' a weak pointer. 
   
   With this PR included, LOG4CXX_322 is still a probem. I still eventually get 
a SegFault in multithreadtest using the following:
   ```
   while ctest -R multi; do i=`expr $i + 1`; echo Done $i; done;
   ```
   
   However, with 'm->priv->repository' a weak pointer, getLoggerRepository() 
should return a spi::LoggerRepositoryPtr (i.e. getLoggerRepository() should 
call lock()), so the caller does not need to call lock().  




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to