summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNick Bray <ncbray@google.com>2018-10-10 14:22:46 -0700
committerNick Bray <ncbray@google.com>2018-10-10 14:22:46 -0700
commit82f9107a0a0d057212b4e62ff5b3772845b4ab24 (patch)
tree12e41971991c6865a4491d11d8f14cd3041c4d41
parent1f4fafab76eaccfe797974f3924281d75e83f436 (diff)
downloadgatekeeper-82f9107a0a0d057212b4e62ff5b3772845b4ab24.tar.gz
Whitelist variable-length arrays for gatekeeper.
This will allow -Wvla to be turned on for the rest of the code base. In the future the use of VLAs in gatekeeper should be eliminated. Bug: 114232578 Change-Id: If5027563dea26039fa06c573ccf93ed17394c748
-rw-r--r--rules.mk6
1 files changed, 6 insertions, 0 deletions
diff --git a/rules.mk b/rules.mk
index ee97cab..fa73cab 100644
--- a/rules.mk
+++ b/rules.mk
@@ -36,6 +36,12 @@ MODULE_INCLUDES += \
$(LOCAL_DIR) \
$(TRUSTY_TOP)/hardware/libhardware/include
+# Gatekeeper uses variable-length arrays to concatinate a salt with a password.
+# The code should be changed to either use malloc or explicitly pass each piece
+# of data to the hash function.
+# TODO(ncbray): remove the VLA and turn the warning back on.
+MODULE_COMPILEFLAGS := -Wno-vla
+
include $(LOCAL_DIR)/$(IPC)/rules.mk
include make/module.mk