Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Tom Tromey <tromey@redhat.com>
To: Phil Muldoon <pmuldoon@redhat.com>
Cc: gdb-patches ml <gdb-patches@sourceware.org>
Subject: Re: [patch][python] Implement Python lazy strings (PR 10705)
Date: Wed, 13 Jan 2010 18:13:00 -0000	[thread overview]
Message-ID: <m36375j2k2.fsf@fleche.redhat.com> (raw)
In-Reply-To: <4B4DDD7B.5080204@redhat.com> (Phil Muldoon's message of "Wed, 13 	Jan 2010 14:49:31 +0000")

>>>>> "Phil" == Phil Muldoon <pmuldoon@redhat.com> writes:

Phil> Here is an updated patch. What do you think?

A couple more notes.

Phil> +gdbpy_extract_lazy_string (PyObject *string, struct type **str_type,
Phil> +		     long *length, char **encoding)
Phil> +{
[...]
Phil> +  py_len = PyObject_GetAttrString (string, "length");
Phil> +  py_encoding = PyObject_GetAttrString (string, "encoding");
Phil> +  py_addr = PyObject_GetAttrString (string, "address");
Phil> +  py_type = PyObject_GetAttrString (string, "type");
[...]
Phil> +  Py_DECREF (py_len);
Phil> +  Py_XDECREF (py_encoding);

Nothing ever frees py_addr or py_type.
This is true for the error case as well.

Phil> +PyObject *execute_pretty_printer (PyObject *printer);

This is declared but never defined or used.

Tom


  reply	other threads:[~2010-01-13 18:13 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-01-08 14:52 Phil Muldoon
2010-01-08 16:25 ` Eli Zaretskii
2010-01-11 15:40   ` Phil Muldoon
2010-01-11 19:10     ` Eli Zaretskii
2010-01-11 21:08 ` Tom Tromey
2010-01-11 21:30   ` Phil Muldoon
2010-01-11 21:40     ` Phil Muldoon
2010-01-12 17:02     ` Tom Tromey
2010-01-13 14:49   ` Phil Muldoon
2010-01-13 18:13     ` Tom Tromey [this message]
2010-01-13 20:23       ` Phil Muldoon
2010-01-13 20:33         ` Tom Tromey
2010-01-14 21:24           ` Phil Muldoon
2010-01-13 18:24     ` Eli Zaretskii

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=m36375j2k2.fsf@fleche.redhat.com \
    --to=tromey@redhat.com \
    --cc=gdb-patches@sourceware.org \
    --cc=pmuldoon@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox