EldoS | Feel safer!

Software components for data protection, secure storage and transfer

Possible BUG - CbfltReadC

Posted: 08/25/2008 06:29:35
by Joe Portman (Basic support level)
Joined: 05/28/2008
Posts: 21

Using C# app. When opening a file and reading I receive a postion, a buffer and a size of read.

unsafe void CbFltReadFileC(
        object Sender,
        string FileName,
        Int64 Position,
        IntPtr Buffer,
        Int32 BytesToRead,
        ref IntPtr UserContext,
        ref bool ProcessRequest

On a file of 281623 bytes, the read is 281623.

I convert the buffer to a pointer and call a routine that examines each byte:

byte* b = (byte*)Buffer.ToPointer();

Examine bytes simply assigns a byte from each byte of the buffer like so:
byte c;
for (int i = 0; i < BytesToRead;i++)
c = b[i];

This blows up, more often than not on byte 8112, with:

"Attempt to read or write protected memory".

Posted: 08/26/2008 06:25:49
by Vladimir Cherniga (Team)

Thanks for report, we will check and make a fix if this error will be confirmed asap.



Topic viewed 4516 times

Number of guests: 1, registered members: 0, in total hidden: 0


Back to top

As of July 15, 2016 EldoS business operates as a division of /n software, inc. For more information, please read the announcement.

Got it!