views:

10

answers:

0

Hello!

I am trying to adapt swapBuffers sample on WDK so that the swapped buffer is the same one than original buffer but in upper case. Modifying this lines on SwapPostReadBuffers() it doesn't work... I get execution errors. Can anyone help me to do it? THANKS

// We suppose that input data are always characters in lower case.

UCHAR *temp;

try {
  temp=(UCHAR*)p2pCtx->SwappedBuffer;  
  for(i=0;i<Data->IoStatus.Information;i++)
  {
      temp[i]=temp[i]-32;
  }
  RtlCopyMemory(origBuf,temp,Data->IoStatus.Information);
}