Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: "Martin M. Hunt" <hunt@redhat.com>
To: <gdb-patches@sources.redhat.com>
Subject: [RFA] info_sharedlibrary_command patch
Date: Mon, 19 Feb 2001 16:52:00 -0000	[thread overview]
Message-ID: <Pine.SUN.4.33.0102191649590.2670-100000@rtl.cygnus.com> (raw)

info_sharedlibrary_command() currently casts all addresses to long before
printing them.  Obviously this fails if pointers are larger than longs.

2001-02-19  Martin M. Hunt  <hunt@redhat.com>

	* solib.c (info_sharedlibrary_command): Don't assume pointers
	are the same size of long, call	longest_local_hex_string_custom().

Index: solib.c
===================================================================
RCS file: /cvs/src/src/gdb/solib.c,v
retrieving revision 1.34
diff -u -p -r1.34 solib.c
--- solib.c	2001/02/19 11:47:16	1.34
+++ solib.c	2001/02/20 00:19:51
@@ -638,14 +638,14 @@ info_sharedlibrary_command (char *ignore

 	  printf_unfiltered ("%-*s", addr_width,
 			     so->textsection != NULL
-			       ? local_hex_string_custom (
-			           (unsigned long) so->textsection->addr,
+			       ? longest_local_hex_string_custom (
+			           (LONGEST) so->textsection->addr,
 	                           addr_fmt)
 			       : "");
 	  printf_unfiltered ("%-*s", addr_width,
 			     so->textsection != NULL
-			       ? local_hex_string_custom (
-			           (unsigned long) so->textsection->endaddr,
+			       ? longest_local_hex_string_custom (
+			           (LONGEST) so->textsection->endaddr,
 	                           addr_fmt)
 			       : "");
 	  printf_unfiltered ("%-12s", so->symbols_loaded ? "Yes" : "No");


             reply	other threads:[~2001-02-19 16:52 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-02-19 16:52 Martin M. Hunt [this message]
2001-02-19 18:35 ` Kevin Buettner

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=Pine.SUN.4.33.0102191649590.2670-100000@rtl.cygnus.com \
    --to=hunt@redhat.com \
    --cc=gdb-patches@sources.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