httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Plüm, Rüdiger, Vodafone Group <ruediger.pl...@vodafone.com>
Subject AW: svn commit: r1811192 - /httpd/httpd/trunk/.gdbinit
Date Mon, 09 Oct 2017 13:50:40 GMT
Does r1811570 fix your issue?

Regards

Rüdiger

Von: Luca Toscano [mailto:toscano.luca@gmail.com]
Gesendet: Montag, 9. Oktober 2017 15:34
An: Apache HTTP Server Development List <dev@httpd.apache.org>
Betreff: Re: svn commit: r1811192 - /httpd/httpd/trunk/.gdbinit

Hi Ruediger,

2017-10-05 14:01 GMT+02:00 <rpluem@apache.org<mailto:rpluem@apache.org>>:
Author: rpluem
Date: Thu Oct  5 12:01:25 2017
New Revision: 1811192

URL: http://svn.apache.org/viewvc?rev=1811192&view=rev
Log:
* Add dump_all_pools and dump_pool_and_childs.

  - dump_all_pools: Dump the whole pool hierarchy starting from apr_global_pool.
                    Requires an arbitrary pool as starting parameter.
  - dump_pool_and_childs: Dump the whole pool hierarchy starting from
                          the given pool.

  dump_pool_and_childs is written in Python using the GDB Python API
  as doing recursive stuff in standard GDB macros is very difficult.

Modified:
    httpd/httpd/trunk/.gdbinit

Modified: httpd/httpd/trunk/.gdbinit
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/.gdbinit?rev=1811192&r1=1811191&r2=1811192&view=diff
==============================================================================
--- httpd/httpd/trunk/.gdbinit (original)
+++ httpd/httpd/trunk/.gdbinit Thu Oct  5 12:01:25 2017
@@ -413,6 +413,98 @@ define dump_one_pool
     printf "' [%p]: %d/%d free (%d blocks)\n", $p, $free, $size, $nodes
 end

+define dump_all_pools
[..]
+    print "Pool '%s' [%s]: %d/%d free (%d blocks) allocator: %s free blocks in allocator:
%i kiB" % (tag, arg, free, size, nodes, darg['allocator'], self._allocator_free_blocks(darg['allocator']))

Not sure if I am the only one that has gdb linked with python3.x but this is what I get now:

  File "<string>", line 47
    print "Pool '%s' [%s]: %d/%d free (%d blocks) allocator: %s free blocks in allocator:
%i kiB" % (tag, arg, free, size, nodes, darg['allocator'], self._allocator_free_blocks(darg['allocator']))
SyntaxError: invalid syntax

Would it be worth to use something like "from future import __print_function__" and add ()
to all the prints?

Thanks!

Luca

Mime
View raw message