[Mono-dev] Open source .Net, and TLS 1.1 & 1.2

Eberhard Beilharz eb1 at sil.org
Mon Dec 15 07:36:10 UTC 2014


Wouldn't

#if __MonoCS__

do what you want?
 

Mono <edward.harvey.mono at clevertrove.com> wrote on 2014-12-14 at 18:44 +0100:
>> From: Alexander Köplinger [mailto:alex.koeplinger at outlook.com]
>>
>> You can find out if you run on Mono by checking if Type.GetType
>> ("Mono.Runtime") != null.
> That's helpful, but doesn't quite solve it, because compilation will fail on windows ...
>
> I'm looking for something like this...
>
> #ifdef MONO
>             Mono.Security.X509.X509StoreManager.CurrentUser.TrustedRoot.Import(junkRootCert);
>             try
>             {
> #endif
>                 DoStuff();
> #ifdef MONO
>             }
>             finally
>             {
>                 Mono.Security.X509.X509StoreManager.CurrentUser.TrustedRoot.Remove(junkRootCert);
>             }
> #endif
> _______________________________________________
> Mono-devel-list mailing list
> Mono-devel-list at lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-devel-list

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.ximian.com/pipermail/mono-devel-list/attachments/20141215/8c9a1d45/attachment-0001.html>


More information about the Mono-devel-list mailing list