File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -11,13 +11,14 @@ internal static class Opcode
11
11
12
12
public static bool Open ( )
13
13
{
14
- //Look for an environment variable: "NETQM_SUPPRESS_RDTSC" with a value of "TRUE"
14
+ //Look for an environment variable: "NETQM_SUPPRESS_RDTSC" with any value
15
15
// The application can set this environment variable when this code is running in a system where
16
16
// it is not desirable to read the processor's time stamp counter.
17
17
// While this is supported in modern CPUs, the technique used for allocating executable memory, copying OP Code
18
18
// for the read of the time stamp and invoking the OP Code can be detected as Malware by some anti-virus vendors.
19
- var val = Environment . GetEnvironmentVariable ( "NETQM_SUPPRESS_RDTSC" ) ;
20
- if ( "TRUE" . Equals ( val , StringComparison . OrdinalIgnoreCase ) )
19
+ // https://github.com/zeromq/netmq/issues/1071
20
+ string val = Environment . GetEnvironmentVariable ( "NETQM_SUPPRESS_RDTSC" ) ;
21
+ if ( ! string . IsNullOrEmpty ( val ) )
21
22
return false ;
22
23
#if NETSTANDARD1_1_OR_GREATER || NET471_OR_GREATER
23
24
if ( RuntimeInformation . ProcessArchitecture != Architecture . X86 &&
You can’t perform that action at this time.
0 commit comments