File tree Expand file tree Collapse file tree 1 file changed +2
-4
lines changed
tests/assembly-llvm/stack-protector Expand file tree Collapse file tree 1 file changed +2
-4
lines changed Original file line number Diff line number Diff line change 99//@ [strong] compile-flags: -Z stack-protector=strong
1010//@ [none] compile-flags: -Z stack-protector=none
1111//@ [safestack] compile-flags: -Z stack-protector=none -Z sanitizer=safestack
12- // RUSTFLAGS: -Cunsafe-allow-abi-mismatch=sanitizer
1312//@ [safestack_strong] compile-flags: -Z stack-protector=strong -Z sanitizer=safestack
14- // RUSTFLAGS: -Cunsafe-allow-abi-mismatch=sanitizer
1513//@ [safestack_all] compile-flags: -Z stack-protector=all -Z sanitizer=safestack
16- // RUSTFLAGS: -Cunsafe-allow-abi-mismatch=sanitizer
1714//@ compile-flags: -C opt-level=2 -Z merge-functions=disabled
1815
16+ #![ no_std]
1917#![ crate_type = "lib" ]
2018#![ allow( internal_features) ]
2119#![ feature( unsized_fn_params) ]
2523#[ no_mangle]
2624pub unsafe fn test1 ( src : * const u8 , len : usize ) -> u8 {
2725 let mut buf = [ 0u8 ; 64 ] ;
28- std :: ptr:: copy_nonoverlapping ( src, buf. as_mut_ptr ( ) , len. min ( buf. len ( ) ) ) ;
26+ core :: ptr:: copy_nonoverlapping ( src, buf. as_mut_ptr ( ) , len. min ( buf. len ( ) ) ) ;
2927 buf[ 0 ]
3028
3129 // none-NOT: __stack_chk_fail
You can’t perform that action at this time.
0 commit comments