Skip to contentSkip to conversation

misc: lkdtm: fixed static variable initialization

PATCH New Parth Y Shah 1 participant 1 message Aug 6, 2018

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 misc: lkdtm: fixed static variable initialization

Resolved "ERROR: do not initialise statics to 0"

---
 drivers/misc/lkdtm/usercopy.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/misc/lkdtm/usercopy.c +1 -1
index 9725aed..d8157b8 100644
@@ -18,7 +18,7 @@
  * hardened usercopy checks by added "unconst" to all the const copies,
  * and making sure "cache_size" isn't optimized into a const.
  */
-static volatile size_t unconst = 0;
+static volatile size_t unconst;
 static volatile size_t cache_size = 1024;
 static struct kmem_cache *whitelist_cache;
 
Signature · 1 line
2.7.4