Fix build for PNaCl.

PNaCl builds BoringSSL with OPENSSL_NO_ASM, but the new OPENSSL_cleanse
was using inline assembly anyway. It appears that even though the inline
asm was empty, it still breaks the PNaCl build:

disallowed: inline assembly: call void asm sideeffect "", "r,~{memory}"(i8* %.asptr319), !dbg !96986

With this change, we don't have any compiler scarecrows for
OPENSSL_cleanse any longer when using OPENSSL_NO_ASM :( Maybe, one day,
we'll get memset_s in our base platform.

Change-Id: Ia359f6bcc2000be18a6f15de10fc683452151741
Reviewed-on: https://boringssl-review.googlesource.com/1353
Reviewed-by: David Benjamin <davidben@chromium.org>
Reviewed-by: Adam Langley <agl@google.com>
diff --git a/crypto/mem.c b/crypto/mem.c
index e9c035e..e35d98b 100644
--- a/crypto/mem.c
+++ b/crypto/mem.c
@@ -96,6 +96,7 @@
 void OPENSSL_cleanse(void *ptr, size_t len) {
   memset(ptr, 0, len);
 
+#if !defined(OPENSSL_NO_ASM)
   /* As best as we can tell, this is sufficient to break any optimisations that
      might try to eliminate "superfluous" memsets. If there's an easy way to
      detect memset_s, it would be better to use that. */
@@ -104,6 +105,7 @@
 #else
   __asm__ __volatile__("" : : "r"(ptr) : "memory");
 #endif
+#endif  /* !OPENSSL_NO_ASM */
 }
 
 int CRYPTO_memcmp(const void *in_a, const void *in_b, size_t len) {