News:

Download Pelles C here: http://www.smorgasbordet.com/pellesc/

Main Menu

LZCreateFileW

Started by czerny, October 16, 2014, 12:31:55 AM

Previous topic - Next topic

czerny

I have found in the export table of Kernel32 the function LZCreateFileW.

This is not documented. It is obviously a companion function to the LZxxx functions for file compression.

I have found the following declaration:

ULONG WINAPI LZCreateFileW (IN LPCWSTR FileName,
IN DWORD dwDesiredAccess,
IN DWORD dwShareMode,
IN DWORD dwCreationDisposition,
IN LPWSTR lpString1 );


this is similar to CreateFile(). But I can not guess what lpString1 does.

Any ideas?

frankie

Quote from: czerny on October 16, 2014, 12:31:55 AM
this is similar to CreateFile(). But I can not guess what lpString1 does.

Any ideas?

The name of the file?
"It is better to be hated for what you are than to be loved for what you are not." - Andre Gide

TimoVJL

Just copy filename to buffer even read first 14 bytes from file compressed with option -R
May the source be with you

czerny

Quote from: frankie on October 16, 2014, 01:45:46 PM
Quote from: czerny on October 16, 2014, 12:31:55 AM
this is similar to CreateFile(). But I can not guess what lpString1 does.

Any ideas?

The name of the file?
That is the first parameter.

czerny

Quote from: TimoVJL on October 16, 2014, 04:21:08 PM
Just copy filename to buffer even read first 14 bytes from file compressed with option -R
I don't understand.

TimoVJL

Quote from: czerny on October 16, 2014, 11:47:23 PM
Quote from: TimoVJL on October 16, 2014, 04:21:08 PM
Just copy filename to buffer even read first 14 bytes from file compressed with option -R
I don't understand.
That function just copy 1. parameter as filename to 4. parameter as string buffer.
Test file was packed with compress.exe option -R so there was information of last char for filename 'l'
lz32.dl_ -> lz32.dll

Some info here
May the source be with you

czerny

Quote from: TimoVJL on October 17, 2014, 08:44:11 AM
Quote from: czerny on October 16, 2014, 11:47:23 PM
Quote from: TimoVJL on October 16, 2014, 04:21:08 PM
Just copy filename to buffer even read first 14 bytes from file compressed with option -R
I don't understand.
That function just copy 1. parameter as filename to 4. parameter as string buffer.
Test file was packed with compress.exe option -R so there was information of last char for filename 'l'
lz32.dl_ -> lz32.dll

Some info here
Thank you! That's it.