Bad call parameters for cdecl nested procedure
Original Reporter info from Mantis: Derek
-
Reporter name:
Original Reporter info from Mantis: Derek
- Reporter name:
Description:
If a nested procedure is declared as "cdecl", then the parameters are all offset by 1. For the following nested procedure declaration
procedure test(a,b,c); decl;
then (ignoring parameter types)
c is frame pointer address of parent? (not confirmed)
b is c
a is b
Additional information:
In this particular case, the procedure code calls a C routine with a callback routine (e.g. test above).
Luckily no access to local variables where required.
Changed the nested procedure to a standard procedure which resolved the issue.
Mantis conversion info:
- Mantis ID: 19617
- OS: Windows 7
- Platform: x86
- Version: 2.4.3