Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Mike Frysinger via Gdb-patches <gdb-patches@sourceware.org>
To: "Павел Крюков" <kryukov@frtk.ru>
Cc: Simon Marchi <simark@simark.ca>, gdb-patches@sourceware.org
Subject: Re: [PATCH] sim-utils.c: prevent buffer overflow.
Date: Fri, 15 Jan 2021 00:18:35 -0500	[thread overview]
Message-ID: <20210115051835.GN6938@vapier> (raw)
In-Reply-To: <3BB98D48-787F-49C4-81F4-736AFFF3516C@frtk.ru>

[-- Attachment #1: Type: text/plain, Size: 807 bytes --]

On 01 Dec 2019 18:33, Павел Крюков wrote:
> 1 дек. 2019 г., в 17:46, Simon Marchi <simark@simark.ca> написал(а):
> > Is the sim built in C++ like GDB?  If so, maybe this function could return
> > an std::string, so there's no more concerns of allocating a static buffer
> > with sufficient space?
>
> No, simulators are built in C. Probably they may be switched to C++, but that would require more effort; plus, there may be external C simulators.

i've been thinking about the sim & C-vs-C++.  the only reason i
hesitate to go all in is that we provide libsim.a for people to
link the runtime into other programs, and providing a static lib
that requires C++ feels wrong.

gdb has the advantage that it doesn't provide a library interface.
maybe it should ...
-mike

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

  reply	other threads:[~2021-01-15  5:18 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-11-30 22:54 Pavel I. Kryukov
2019-12-01 14:46 ` Simon Marchi
2019-12-01 15:33   ` Павел Крюков
2021-01-15  5:18     ` Mike Frysinger via Gdb-patches [this message]
2019-12-02 10:09 ` Andrew Burgess
2019-12-02 12:00   ` Pavel I. Kryukov
2019-12-02 19:06     ` Pavel I. Kryukov
2019-12-02 21:20       ` Andrew Burgess
2019-12-03  9:47         ` Pavel I. Kryukov
2019-12-04 17:39           ` Tom Tromey

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=20210115051835.GN6938@vapier \
    --to=gdb-patches@sourceware.org \
    --cc=kryukov@frtk.ru \
    --cc=simark@simark.ca \
    --cc=vapier@gentoo.org \
    /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