How to use LZO.dll

Aug 31 2007 3:37 AM
Hi all, Iam using lzo.dll in C#.net project. Code is

public byte[] Decompress(byte[] src) {
            if(_traceSwitch.TraceVerbose) {
                Trace.WriteLine(String.Format("LZOCompressor: trying to decompress {0}", src.Length));
            }
            int origlen = BitConverter.ToInt32(src, src.Length - 4);
            byte[] dst = new byte[origlen];
            int outlen = 600;
            lzo1x_decompress(src, (src.Length - 4), dst, ref outlen, _workMemory);
            if(_traceSwitch.TraceVerbose) {
                Trace.WriteLine(String.Format("LZOCompressor: decompressed {0} to {1} bytes", src.Length, origlen));
            }
            return dst;

}
but when i call this function its giving an error
 'System.ExecutionEngineException' ......and stick on the line "lzo1x_decompress(src, (src.Length - 4), dst, ref outlen, _workMemory);"

Plzz help me to solve this.