LCOV - code coverage report
Current view: top level - flamenco/runtime/sysvar - fd_sysvar_rent1.c (source / functions) Hit Total Coverage
Test: cov.lcov Lines: 4 4 100.0 %
Date: 2025-07-01 05:00:49 Functions: 1 1 100.0 %

          Line data    Source code
       1             : #include "fd_sysvar_rent.h"
       2             : 
       3             : /* Moved into a separate compile unit to minimize dependencies on fd_funk */
       4             : 
       5             : /* https://github.com/solana-labs/solana/blob/8f2c8b8388a495d2728909e30460aa40dcc5d733/sdk/program/src/rent.rs#L36 */
       6         108 : #define ACCOUNT_STORAGE_OVERHEAD (128)
       7             : 
       8             : ulong
       9             : fd_rent_exempt_minimum_balance( fd_rent_t const * rent,
      10         108 :                                 ulong             data_len ) {
      11             :   /* https://github.com/anza-xyz/agave/blob/d2124a995f89e33c54f41da76bfd5b0bd5820898/sdk/program/src/rent.rs#L74 */
      12         108 :   return fd_rust_cast_double_to_ulong( (double)((data_len + ACCOUNT_STORAGE_OVERHEAD) * rent->lamports_per_uint8_year) * rent->exemption_threshold );
      13         108 : }

Generated by: LCOV version 1.14