[mmotm:master 156/234] lib/test_kasan.c:478:27: sparse: Variable length array is used.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



tree:   git://git.cmpxchg.org/linux-mmotm.git master
head:   a4f20e3ed193cd4b2f742ce37f88112c7441146f
commit: e329261f769afff2744bfeaad6cb7e8c03048e27 [156/234] kasan: add tests for alloca poisoning
reproduce:
        # apt-get install sparse
        git checkout e329261f769afff2744bfeaad6cb7e8c03048e27
        make ARCH=x86_64 allmodconfig
        make C=1 CF=-D__CHECK_ENDIAN__


sparse warnings: (new ones prefixed by >>)


vim +478 lib/test_kasan.c

   474	
   475	static noinline void __init kasan_alloca_oob_left(void)
   476	{
   477		volatile int i = 10;
 > 478		char alloca_array[i];
   479		char *p = alloca_array - 1;
   480	
   481		pr_info("out-of-bounds to left on alloca\n");
   482		*(volatile char *)p;
   483	}
   484	

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@xxxxxxxxx.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@xxxxxxxxx";> email@xxxxxxxxx </a>



[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]
  Powered by Linux