DescriptionExtra logging was added in:
http://code.sixapart.com/trac/djabberd/changeset/799
This new logging makes calls to B::svref_2object, which is apparently some part of the perl compile that allows you to traverse the call stack and figure out who called you.
Example debug output:
For phase [PresenceCheck] invoking hook 1 of 2 defined at: lib/DJabberd/PresenceChecker.pm:26
There seems to be a problem however in some cases. I'm not exactly sure why. But in some case:
$cv->ROOT->first->line
returns the correct line number
while:
$cv->ROOT->first->first->line
causes an error: (Can't locate object method "first" via package "B::COP")
Example callback of this case:
For phase [AlterPresenceAvailable] invoking hook 3 of 3 defined at: lib/DJabberd/VHost.pm:201
So, it seems that instead of blindly calling '$cv->ROOT->first->first->line', the code needs to traverse these B::LISTOP objects to the proper depth to find a B::COP object from which we can get the line number.
Patch Set 1 #
MessagesTotal messages: 1
|