Thread View: sanet.list.sco
1 messages
1 total messages
Started by watson
Wed, 26 Aug 1992 18:16
bug in memc.. intrinsic
Author: watson
Date: Wed, 26 Aug 1992 18:16
Date: Wed, 26 Aug 1992 18:16
17 lines
1219 bytes
1219 bytes
Everyone probably knows this, but I thought I should post it, just incase SCO didn't know it yet. There is a BUG in the intrinsic version of memcpy and similar routines. It is ok as a subroutine, but the intrinsic version does not type cast the lenght to a long. If you call it with a short, it will use whatever junk you had most recently in the high order 16 bits of the register. It can be fixed with a define, but not the (long)(len) that you would first expect. That has problems, but just using len+0, will force the complier to think about it with some arithmetic, and then it gets the right answer. Only a statement or two of extra code is generated, if any. John Watson ... a non-profit re-seller, maby next year I can make some money!
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads