Fixes for miCASAReadBinaryKey and miCASAWriteBinaryKey to work.
This commit is contained in:
parent
74a6359218
commit
8f96e7cbc1
@ -2148,22 +2148,22 @@ int32_t ipc_ReadBinaryKey
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
//buffer allocated by application is not sufficient to hold the data.
|
//buffer allocated by application is not sufficient to hold the data.
|
||||||
*bytesRequired = dataLen;
|
*bytesRequired = dataLen;
|
||||||
{
|
{
|
||||||
// Cleanup the channel by reading the remaining and return error.
|
// Cleanup the channel by reading the remaining and return error.
|
||||||
int n;
|
int n;
|
||||||
n = dataLen;
|
n = dataLen + MSG_DWORD_LEN;
|
||||||
while(n)
|
while(n)
|
||||||
{
|
{
|
||||||
int bytes = IPC_READ(ssHandle->platHandle, gpReplyBuf, MIN_REPLY_BUF_LEN);
|
int bytes = IPC_READ(ssHandle->platHandle, gpReplyBuf, MIN_REPLY_BUF_LEN);
|
||||||
if( bytes > 0)
|
if( bytes > 0)
|
||||||
n -= MIN_REPLY_BUF_LEN;
|
n -= bytes;
|
||||||
else
|
else
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
// Read the sscs return code also.
|
// Read the sscs return code also.
|
||||||
IPC_READ(ssHandle->platHandle, (Byte *) &sockReturn, MSG_DWORD_LEN);
|
// IPC_READ(ssHandle->platHandle, (Byte *) &sockReturn, MSG_DWORD_LEN);
|
||||||
retCode = NSSCS_E_ENUM_BUFF_TOO_SHORT;
|
retCode = NSSCS_E_ENUM_BUFF_TOO_SHORT;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user