Abstract NamedPipes code for windows
This commit is contained in:
		| @@ -216,7 +216,7 @@ namespace Novell.CASA | ||||
| 			[In]		uint	 				ssFlags, 				// IN | ||||
| 			[In]		SSCS_SECRET_ID_T		appSecretID,  | ||||
| 			[In]		SSCS_SECRET_ID_T		sharedSecretID, 						  | ||||
| 			int									credentialType,			// IN | ||||
| 			[In, Out]   ref uint				credentialType,			// IN | ||||
| 			[In, Out]	IntPtr					pCredential,		 | ||||
| 			[In, Out]	SSCS_EXT_T				ext | ||||
| 			); | ||||
| @@ -1038,6 +1038,7 @@ namespace Novell.CASA | ||||
| 				throw new miCasaException(miCasaException.NSSCS_E_INVALID_PARAM); | ||||
|  | ||||
| 			int rcode; | ||||
| 			uint credType = 0; | ||||
| 			BasicCredential bc = null; | ||||
|  | ||||
| 			SSCS_SECRET_ID_T appSecretID = new SSCS_SECRET_ID_T(); | ||||
| @@ -1059,15 +1060,23 @@ namespace Novell.CASA | ||||
| 			IntPtr pCredential = Marshal.AllocHGlobal(Marshal.SizeOf(credential));			 | ||||
| 			Marshal.StructureToPtr(credential, pCredential, false); | ||||
| 			 | ||||
| 			try  | ||||
| 			{ | ||||
| 				rcode = miCASAGetCredential( | ||||
| 					ssFlags, | ||||
| 					appSecretID, | ||||
| 					sharedID, | ||||
| 				0, | ||||
| 					ref credType, | ||||
| 					pCredential, | ||||
| 					new SSCS_EXT_T() | ||||
| 					); | ||||
|               | ||||
| 			} | ||||
| 			catch (Exception e) | ||||
| 			{ | ||||
| 				Console.WriteLine(e.ToString()); | ||||
| 				Marshal.FreeHGlobal(pCredential); | ||||
| 				throw new miCasaException(-803); | ||||
| 			} | ||||
|  | ||||
| 			if (rcode == 0) | ||||
| 			{ | ||||
|   | ||||
		Reference in New Issue
	
	Block a user