File tree Expand file tree Collapse file tree 1 file changed +7
-4
lines changed Expand file tree Collapse file tree 1 file changed +7
-4
lines changed Original file line number Diff line number Diff line change @@ -630,7 +630,8 @@ pub unsafe extern "C" fn rustsecp256k1_v0_3_1_default_error_callback_fn(message:
630630 panic ! ( "[libsecp256k1] internal consistency check failed {}" , msg) ;
631631}
632632
633-
633+ #[ no_mangle]
634+ #[ cfg( not( feature = "external-symbols" ) ) ]
634635unsafe fn strlen ( mut str_ptr : * const c_char ) -> usize {
635636 let mut ctr = 0 ;
636637 while * str_ptr != '\0' as c_char {
@@ -1161,11 +1162,13 @@ pub use self::fuzz_dummy::*;
11611162
11621163#[ cfg( test) ]
11631164mod tests {
1164- use std:: ffi:: CString ;
1165- use super :: strlen;
1166-
1165+ #[ no_mangle]
1166+ #[ cfg( not( feature = "external-symbols" ) ) ]
11671167 #[ test]
11681168 fn test_strlen ( ) {
1169+ use std:: ffi:: CString ;
1170+ use super :: strlen;
1171+
11691172 let orig = "test strlen \t \n " ;
11701173 let test = CString :: new ( orig) . unwrap ( ) ;
11711174
You can’t perform that action at this time.
0 commit comments