Using NT registry calls to solve CR-LF issue with text files.

Matthias Wächter matthias at waechter.wol.at
Mon Feb 7 00:11:45 GMT 2000


On Mon, 7 Feb 2000, John E. Malmberg wrote:

> Windows actually uses two methods of determining a file type.  The first is
> a registry, and the second is to examine the first two bytes of the file for
> a signature.  Some programs use the signature over the file type.

Isn't there a third variant? Having WinZip installed, some .EXE files are
in fact self-extracting .ZIP files and thus have the "Open with WinZip"
and "Extract to..." entries in their context menues in the Explorer. I
think this works with the Explorer Shell Extensions - intelligent filter
programs able to analyze the contents of a file.

Maybe we write some interface to something like "Samba Shell Extensions"
...? Intelligent filters for special file types deciding by themselves how
to transmit/receive data for these files. F.e. one could write a filter in
a way that all .txt files will be stored with Unix-like CR/LF -> LF
translation and presented to Samba clients with LF -> CR/LF translation.

Just a thought.

Sehr Wus,
- Matthias

-- 
"Fire! Fire!!! FIRE!!!!!
                           cat?"
(from Pleasantville)
-----------------------------------------------------------------------------



More information about the samba-technical mailing list