TIP: Click on subject to list as thread! ANSI
echo: os2prog
to: Herbert Bushong
from: James Mckenzie
date: 1998-10-09 17:53:08
subject: Need to copy

Hello Herbert!

08 Oct 98 04:08, Herbert Bushong wrote to James McKenzie:

 ::>> I received a program which uses memcpy to copy from one variable
 ::>> to anothe which are built on the same structure.  Other than doing
 ::>> the copy the hard what function can I use?

 ::>> This is with Borland C++ for OS/2.

 HB> BC/2 doesn't have memcpy? I thought it did...   Use memmove()...

Ok.  Let me state what happened again.  I tried to use memcpy and I ended
up with a SYS1808.  Calling the FUNCTION with the same code compiled with
Watcom C/C++ 10.0a results in the same error message. Something is wrong
with either the structure or the method of accessing the function.

The call is calc_offered_load (&ex);

And the function line is
void calc_offered_load (EXPT_DESC_PTR expt)
{ Code in here }
ex is of type EXPT_DESC

And the structure ends with:

} EXPT_DESC  *EXPT_DESC_PTR

which from what I remember makes expt a pointer to the variable ex.

James

... OS/2...Opens up Windows, shuts up Gates.
--- GoldED/2 2.50+
* Origin: OS/2 Support * Your place for OS/2 information and Files (1:309/63)
SEEN-BY: 396/1 632/0 371 633/210 260 267 270 371 635/506 728 639/252 670/218
@PATH: 309/63 396/1 633/260 635/506 728 633/267

SOURCE: echomail via fidonet.ozzmosis.com

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.