delorie.com/archives/browse.cgi | search |
X-Authentication-Warning: | delorie.com: mailnull set sender to djgpp-bounces using -f |
Date: | Fri, 17 May 2002 12:50:06 +0300 |
From: | "Eli Zaretskii" <eliz AT is DOT elta DOT co DOT il> |
Sender: | halo1 AT zahav DOT net DOT il |
To: | djgpp AT delorie DOT com |
Message-Id: | <6137-Fri17May2002125005+0300-eliz@is.elta.co.il> |
X-Mailer: | emacs 21.2.50 (via feedmail 8 I) and Blat ver 1.8.9 |
In-reply-to: | <3ce499a4.67660852@news.adelaide.on.net> (degoble@gtech) |
Subject: | Re: help: worked in turbo c/c++ for dos, but not in djgpp gcc |
References: | <3ce499a4 DOT 67660852 AT news DOT adelaide DOT on DOT net> |
Reply-To: | djgpp AT delorie DOT com |
Errors-To: | nobody AT delorie DOT com |
X-Mailing-List: | djgpp AT delorie DOT com |
X-Unsubscribes-To: | listserv AT delorie DOT com |
> From: degoble AT gtech > Newsgroups: comp.os.msdos.djgpp > Date: Fri, 17 May 2002 05:53:40 GMT > > What is wrong with this code; This is what's wrong: > char *text, *temp; > > strcpy(text, title); The variable `text' is a pointer that you didn't initialize, so it points to a random location in memory. When you copy text to that location, you are committing a crime punishable by crash.
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |