Path: ...!2.eu.feeder.erje.net!feeder.erje.net!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: Tim Rentsch
Newsgroups: comp.lang.c
Subject: Re: relearning C: why does an in-place change to a char* segfault?
Date: Tue, 13 Aug 2024 17:41:16 -0700
Organization: A noiseless patient Spider
Lines: 6
Message-ID: <86cymcszpv.fsf@linuxsc.com>
References: <87jzh0gdru.fsf@nosuchdomain.example.com> <865xs54fak.fsf@linuxsc.com> <8734n8gp8v.fsf@nosuchdomain.example.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Injection-Date: Wed, 14 Aug 2024 02:41:16 +0200 (CEST)
Injection-Info: dont-email.me; posting-host="088cfa383a3af87f6acebe452dc28057";
logging-data="158184"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18zZX81eduIBw7IzBfarNFNNreFOim611Q="
User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.4 (gnu/linux)
Cancel-Lock: sha1:yYdKEeN80D8iPYq0InRBVC5CMUU=
sha1:I0H85q6pJiCnykqniBW33/4v+i0=
Bytes: 1444
Keith Thompson writes:
> In 20/20 hindsight, my personal opinion is that it would have been
> better to make string literals const in C89/C90.
Fortunately wiser heads prevailed.