summaryrefslogtreecommitdiffstats
path: root/crypto/x86cpuid.pl
diff options
context:
space:
mode:
authorAndy Polyakov <appro@openssl.org>2010-01-24 15:54:24 +0100
committerAndy Polyakov <appro@openssl.org>2010-01-24 15:54:24 +0100
commit7676eebf4297c8ccb27a6517eb8529cbd187f17a (patch)
tree8668e00dc37bdb3b027f34331e810578aaf7d02c /crypto/x86cpuid.pl
parentThe fix for PR#1949 unfortunately broke cases where the BIO_CTRL_WPENDING (diff)
downloadopenssl-7676eebf4297c8ccb27a6517eb8529cbd187f17a.tar.xz
openssl-7676eebf4297c8ccb27a6517eb8529cbd187f17a.zip
OPENSSL_cleanse to accept zero length parameter [matching C implementation].
Diffstat (limited to 'crypto/x86cpuid.pl')
-rw-r--r--crypto/x86cpuid.pl3
1 files changed, 3 insertions, 0 deletions
diff --git a/crypto/x86cpuid.pl b/crypto/x86cpuid.pl
index e5dcc58124..a7464af19b 100644
--- a/crypto/x86cpuid.pl
+++ b/crypto/x86cpuid.pl
@@ -279,11 +279,14 @@ for (@ARGV) { $sse2=1 if (/-DOPENSSL_IA32_SSE2/); }
&xor ("eax","eax");
&cmp ("ecx",7);
&jae (&label("lot"));
+ &cmp ("ecx",0);
+ &je (&label("ret"));
&set_label("little");
&mov (&BP(0,"edx"),"al");
&sub ("ecx",1);
&lea ("edx",&DWP(1,"edx"));
&jnz (&label("little"));
+&set_label("ret");
&ret ();
&set_label("lot",16);