| 4 | | It is also incorrect to thunk these two pointers and copy them back into the EAOP return structure. These pointers HAVE to remain 16:16 far pointers in the returned kernel structure. |
| | 4 | It is also incorrect to thunk these two pointers and copy them back into the EAOP return structure as is done here: |
| | 5 | |
| | 6 | {{{ |
| | 7 | if (level == FIL_QUERYEASFROMLIST || level == FIL_QUERYEASFROMLISTL) |
| | 8 | { |
| | 9 | KernCopyIn(&eaop, pbData, sizeof (EAOP)); |
| | 10 | pFeal = (PFEALIST)RTMemAlloc(MIN_EA_SIZE); |
| | 11 | |
| | 12 | if (! pFeal) |
| | 13 | { |
| | 14 | hrc = ERROR_NOT_ENOUGH_MEMORY; |
| | 15 | goto FILLFINDBUFEXIT; |
| | 16 | } |
| | 17 | |
| | 18 | eaop.fpFEAList = pFeal; |
| | 19 | eaop.fpGEAList = (PGEALIST)KernSelToFlat((ULONG)eaop.fpGEAList); |
| | 20 | } |
| | 21 | |
| | 22 | memset(pbData, 0, cbData); |
| | 23 | |
| | 24 | if (level == FIL_QUERYEASFROMLIST || level == FIL_QUERYEASFROMLISTL) |
| | 25 | { |
| | 26 | KernCopyOut(pbData, &eaop, sizeof(EAOP)); |
| | 27 | pbData += sizeof(EAOP); |
| | 28 | cbData -= sizeof(EAOP); |
| | 29 | }}} |
| | 30 | |
| | 31 | These pointers HAVE to remain 16:16 far pointers in the returned kernel structure. |