cryptobox-c
cryptobox-c copied to clipboard
Valgrind tests fail on Bookworm
$ make test
cargo build
warning: attribute should be applied to a free function, impl method or static
--> src/lib.rs:46:1
|
46 | #[no_mangle]
| ^^^^^^^^^^^^
47 | #[derive(Clone, Copy, Debug, Eq, PartialEq)]
48 | / pub enum CBoxIdentityMode {
49 | | Complete = 0,
50 | | Public = 1
51 | | }
| |_- not a free function, impl method or static
|
= note: `#[warn(unused_attributes)]` on by default
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
warning: attribute should be applied to a free function, impl method or static
--> src/lib.rs:351:1
|
351 | #[no_mangle]
| ^^^^^^^^^^^^
352 | #[derive(Clone, Copy, Debug)]
353 | / pub enum CBoxResult {
354 | | Success = 0,
355 | | StorageError = 1,
356 | | SessionNotFound = 2,
... |
371 | | DegeneratedKey = 17
372 | | }
| |_- not a free function, impl method or static
|
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
warning: `cryptobox-c` (lib) generated 2 warnings
Finished dev [unoptimized + debuginfo] target(s) in 0.46s
mkdir -p test/target
cp target/debug/libcryptobox.so test/target/libcryptobox.so
rm -f test/target/main
cc -std=c99 -Wall -Wextra -Werror -g test/main.c -o test/target/main -Isrc -Ltest/target -lcryptobox
LD_LIBRARY_PATH=test/target valgrind --leak-check=full --error-exitcode=1 --track-origins=yes test/target/main
==68253== Memcheck, a memory error detector
==68253== Copyright (C) 2002-2022, and GNU GPL'd, by Julian Seward et al.
==68253== Using Valgrind-3.19.0 and LibVEX; rerun with -h for copyright info
==68253== Command: test/target/main
==68253==
alice="/tmp/cbox_test_aliceNgw9Dt", bob="/tmp/cbox_test_bobubbcd1"
test_basics ... OK
ERROR: CBoxError: proteus error: PreKeyNotFound: 1
test_prekey_removal ... OK
test_random_bytes ... OK
ERROR: CBOR decoder error: DecodeError: unexpected type Text (info=14)
test_is_prekey ... OK
test_last_prekey ... OK
ERROR: CBoxError: proteus error: DuplicateMessage
test_duplicate_msg ... OK
test_delete_session ... OK
test_box_reopen ... OK
ERROR: CBoxError: identity error
test_external_identity ... OK
ERROR: CBoxError: identity error
ERROR: CBoxError: identity error
test_wrong_identity ... OK
test_fingerprint_prekey ... OK
==68253==
==68253== HEAP SUMMARY:
==68253== in use at exit: 0 bytes in 0 blocks
==68253== total heap usage: 1,124 allocs, 1,124 frees, 269,456 bytes allocated
==68253==
==68253== All heap blocks were freed -- no leaks are possible
==68253==
==68253== For lists of detected and suppressed errors, rerun with: -s
==68253== ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 0 from 0)