From: Alexandre Oliva <aoliva@redhat.com>
To: Chong Yidong <cyd@stupidchicken.com>
Cc: emacs-pretest-bug@gnu.org
Subject: Re: memory corruption in regex.c
Date: Sun, 23 Mar 2008 01:04:51 -0300 [thread overview]
Message-ID: <orr6e2m6fw.fsf@oliva.athome.lsd.ic.unicamp.br> (raw)
In-Reply-To: <87abkqo33m.fsf@stupidchicken.com> (Chong Yidong's message of "Sat\, 22 Mar 2008 17\:34\:05 -0400")
On Mar 22, 2008, Chong Yidong <cyd@stupidchicken.com> wrote:
>> - re_char *old_buffer = bufp->buffer; \
>> + unsigned char *old_buffer = bufp->buffer; \
> What is the purpose of this?
Compiler warning avoidance. b is unsigned char *, whereas re_char is
const unsigned char *. I suppose it would be enough for new_buffer to
be non-const, but these buffers are not const anyway, and the
constness doesn't buy much at this point.
--
Alexandre Oliva http://www.lsd.ic.unicamp.br/~oliva/
FSF Latin America Board Member http://www.fsfla.org/
Red Hat Compiler Engineer aoliva@{redhat.com, gcc.gnu.org}
Free Software Evangelist oliva@{lsd.ic.unicamp.br, gnu.org}
next prev parent reply other threads:[~2008-03-23 4:04 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-03-22 11:25 memory corruption in regex.c Alexandre Oliva
2008-03-22 21:34 ` Chong Yidong
2008-03-23 4:04 ` Alexandre Oliva [this message]
2008-03-26 22:51 ` Chong Yidong
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=orr6e2m6fw.fsf@oliva.athome.lsd.ic.unicamp.br \
--to=aoliva@redhat.com \
--cc=cyd@stupidchicken.com \
--cc=emacs-pretest-bug@gnu.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.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.