🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.std.c
Article #1743

Re: memcpy

#1743
From: Conor P. Cahill
Date: Fri, 21 Sep 1990 01:52
18 lines
1061 bytes
In article <1990Sep19.021418.11574@maths.tcd.ie> tim@maths.tcd.ie (Timothy Murphy) writes:
>In unzip.c it is assumed that the effect of
>	buf[0] = c;
>	memcpy(buf+1, buf, 20);
>is to set
>	buf[0] = buf[1] = buf[2] = ... = buf[21] = c.

The effect of memcpy on overlapping memory areas is undefined.  unzip.c 
should not depend upon any particular behavior.

>Is this a bug on the Sparc,

No.  it is a bug in unzip.

-- 
Conor P. Cahill            (703)430-9247        Virtual Technologies, Inc.,
uunet!virtech!cpcahil                           46030 Manekin Plaza, Suite 160
                                                Sterling, VA 22170 
Technical Details
Message-ID: <1990Sep21.015204.18893@virtech.uucp>
Path: arc1-ca.pugleaf.net!utzoo!attcan!uunet!virtech!cpcahil
References: <1990Sep19.021418.11574@maths.tcd.ie>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!attcan!uunet!virtech!cpcahil
From: cpcahil@virtech.uucp (Conor P. Cahill)
Newsgroups: comp.std.c
Subject: Re: memcpy
Keywords: memcpy
Message-ID: <1990Sep21.015204.18893@virtech.uucp>
Date: 21 Sep 90 01:52:04 GMT
References: <1990Sep19.021418.11574@maths.tcd.ie>
Reply-To: cpcahil@virtech.UUCP (Conor P. Cahill)
Organization: Virtual Technologies Inc., Sterling VA
Lines: 18