The information in this article applies to:
SYMPTOMSSIZEOF and SIZE drop the high byte of the size for LOCAL variables larger than 255 bytes. The SIZE and SIZEOF for global variables and data types is correct. The TYPE operator works correctly for all variables. RESOLUTIONYou can use the TYPE and LENGTHOF operators to obtain the correct size of local variables. STATUSMicrosoft has confirmed this to be a problem in MASM versions 6.x. We are researching this problem and will post new information here in the Microsoft Knowledge Base as it becomes available. MORE INFORMATIONIn the following example, structure junk1 is 255 bytes and junk2 is 256 bytes. If local variables are used, SIZE and SIZEOF return 0 (zero) for the size of the local variable j2L. This can be seen in the listing file or in CodeView if the program is run in the debugger. Note that the TYPE operator works correctly for single-element variables. To find the size of array types, use TYPE * LENGTHOF as shown for j3L below. Sample Code
Additional query words: 6.00 6.00a 6.00b 6.10 6.10a 6.10b 6.11 ml buglist6.11
Keywords : |
Last Reviewed: January 7, 2000 © 2000 Microsoft Corporation. All rights reserved. Terms of Use. |