These are part of the C Runtime library right? How does one get at them from within asm? I know you can call the windows equivalents like CreateFileA etc. but is there a way of calling these?

I've checked the FAQ but it didn't help much
Posted on 2002-09-05 08:14:45 by timkempster
Look what I found in kernel32.inc ;)

_hread PROTO :DWORD,:DWORD,:DWORD
_hwrite PROTO :DWORD,:DWORD,:DWORD
_lclose PROTO :DWORD
_lcreat PROTO :DWORD,:DWORD
_llseek PROTO :DWORD,:DWORD,:DWORD
_lopen PROTO :DWORD,:DWORD
_lread PROTO :DWORD,:DWORD,:DWORD
_lwrite PROTO :DWORD,:DWORD,:DWORD

Microsoft recommends you to use the ReadFile etc. API's though, these API's above just call to the newer versions.
Posted on 2002-09-05 09:17:17 by Qweerdy
Thanks I also found this http://support.microsoft.com/default.aspx?scid=KB;EN-US;Q99456& which is pretty interesting.

Unfortuately I tried to use someof these and it doesn't work. I'm trying to pass these functions as pointer to a call to FDICreate which is a function in the CABINET.DLL. I was hoping to then call FDICopy to extract files from a cab file using this dll. Unfortunately FDICreate needs the following. I thought I might be able to use _llseek etc. but they don't seem to work.

Thanks for your help. If you have any idea about this I'd be mostest happies


/*** FDICreate - Create an FDI context
*
* Entry:
* pfnalloc
* pfnfree
* pfnopen
* pfnread
* pfnwrite
* pfnclose
* pfnlseek
* cpuType - Select CPU type (auto-detect, 286, or 386+)
* NOTE: For the 32-bit FDI.LIB, this parameter is ignored!
* perf
*
* Exit-Success:
* Returns non-NULL FDI context handle.
*
* Exit-Failure:
* Returns NULL; perf filled in with error code
*
*/
HFDI FAR DIAMONDAPI FDICreate(PFNALLOC pfnalloc,
PFNFREE pfnfree,
PFNOPEN pfnopen,
PFNREAD pfnread,
PFNWRITE pfnwrite,
PFNCLOSE pfnclose,
PFNSEEK pfnseek,
int cpuType,
PERF perf);
:) :)
Posted on 2002-09-05 10:46:02 by timkempster