From: Tom Tromey <tom@tromey.com>
To: Simon Marchi <simark@simark.ca>
Cc: Kamil Rytarowski <n54@gmx.com>,
gdb-patches@sourceware.org, tom@tromey.com
Subject: Re: [PATCH v4] Disable get_ptrace_pid for NetBSD
Date: Fri, 20 Mar 2020 09:50:47 -0600 [thread overview]
Message-ID: <87tv2jkotk.fsf@tromey.com> (raw)
In-Reply-To: <6e74c142-d3e7-6fd8-b765-594931be898b@simark.ca> (Simon Marchi's message of "Thu, 19 Mar 2020 11:30:24 -0400")
>>>>> "Simon" == Simon Marchi <simark@simark.ca> writes:
Simon> Ah, it's because ptrace returns long and not int on GNU/Linux.
Simon> So when we want to read a 64-bits word from memory, it gets
Simon> truncated. gdb_ptrace should return PTRACE_TYPE_RET.
FWIW it's also fine to just return long from our wrapper; at least if
all known ptrace implementations return some integer type.
Simon> In fact, to be consistent, all these gdb_ptrace functions should
Simon> be changed to return PTRACE_TYPE_RET (as a separate patch).
Now that we have C++ we could probably get rid of these autoconf checks
and just use the template instantiation or overloading tricks.
Tom
next prev parent reply other threads:[~2020-03-20 16:02 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-03-18 21:49 [PATCH] " Kamil Rytarowski
2020-03-18 21:51 ` Kamil Rytarowski
2020-03-18 21:55 ` [PATCH v2] " Kamil Rytarowski
2020-03-18 22:21 ` Simon Marchi
2020-03-18 23:30 ` Kamil Rytarowski
2020-03-18 23:16 ` [PATCH v3] " Kamil Rytarowski
2020-03-19 1:13 ` Simon Marchi
2020-03-19 12:01 ` Kamil Rytarowski
2020-03-19 12:28 ` [PATCH v4] " Kamil Rytarowski
2020-03-19 12:55 ` Simon Marchi
2020-03-19 15:30 ` Simon Marchi
2020-03-19 15:51 ` Kamil Rytarowski
2020-03-20 15:50 ` Tom Tromey [this message]
2020-03-19 15:45 ` [PATCH v5] " Kamil Rytarowski
2020-03-19 19:27 ` Simon Marchi
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=87tv2jkotk.fsf@tromey.com \
--to=tom@tromey.com \
--cc=gdb-patches@sourceware.org \
--cc=n54@gmx.com \
--cc=simark@simark.ca \
/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