delorie.com/archives/browse.cgi | search |
Date: | Thu, 24 Aug 2000 12:55:51 -0400 |
Message-Id: | <200008241655.MAA29183@envy.delorie.com> |
From: | DJ Delorie <dj AT delorie DOT com> |
To: | djgpp AT delorie DOT com |
In-reply-to: | <s269qsgaqr5446ot429cat1q8vo7rq5t9c@4ax.com> (message from |
Radical NetSurfer on Wed, 23 Aug 2000 23:37:41 -0400) | |
Subject: | Re: memset behavior |
References: | <s269qsgaqr5446ot429cat1q8vo7rq5t9c AT 4ax DOT com> |
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 |
> There's no such thing as a memcat() routine... > why? How can binary data (data containing 0x00) be > CONCATED to accurately and properly return the > size (pointer growth) of a buffer? There is no memcat because there's no way to tell where the end of the binary data is by inspecting the binary data itself. You have to keep track of the length separately. Since you thus already have the length, you can just use memcpy (like "memcpy(buf+length, tmp, foo); length += foo;")
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |