Fixed problem that was causing the library to crash when ObtainAuthToken was called with a null WinLUID.
This commit is contained in:
parent
a4280ae24b
commit
42e3203ab5
@ -127,7 +127,8 @@ namespace Novell.Casa.Client.Auth
|
|||||||
|
|
||||||
SSCS_EXT_T ext = new SSCS_EXT_T();
|
SSCS_EXT_T ext = new SSCS_EXT_T();
|
||||||
LUID sluid;
|
LUID sluid;
|
||||||
if ((luid != null) && (luid.GetHighPart() != 0) || (luid.GetLowPart() != 0))
|
if ((luid != null) &&
|
||||||
|
((luid.GetHighPart() != 0) || (luid.GetLowPart() != 0)))
|
||||||
{
|
{
|
||||||
// allocate a structure to marshal
|
// allocate a structure to marshal
|
||||||
sluid = new LUID();
|
sluid = new LUID();
|
||||||
@ -155,8 +156,7 @@ namespace Novell.Casa.Client.Auth
|
|||||||
rcode = ObtainAuthToken(baService, baHost, baToken, ref bufferSize);
|
rcode = ObtainAuthToken(baService, baHost, baToken, ref bufferSize);
|
||||||
}
|
}
|
||||||
|
|
||||||
int test = (rcode & BUFFER_OVERFLOW);
|
if ((rcode & 0xFFFF) == BUFFER_OVERFLOW)
|
||||||
if (test == BUFFER_OVERFLOW)
|
|
||||||
{
|
{
|
||||||
// now allocate the proper size
|
// now allocate the proper size
|
||||||
baToken = new byte[bufferSize];
|
baToken = new byte[bufferSize];
|
||||||
|
Loading…
Reference in New Issue
Block a user