Skip to content

Commit

Permalink
fix: wallet ffi header file (#5329)
Browse files Browse the repository at this point in the history
Description
---
Fixes the header file by removing the auto-generated repc command as c
does not have an option.

How Has This Been Tested?
---
manual
  • Loading branch information
SWvheerden authored Apr 17, 2023
1 parent 12a1ef4 commit b0d2032
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 42 deletions.
1 change: 0 additions & 1 deletion base_layer/wallet_ffi/src/ffi_basenode_state.rs
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,6 @@ use crate::{
};

#[derive(Debug)]
#[repr(C)]
pub struct TariBaseNodeState {
/// The ID of the base node this wallet is connected to
pub node_id: Option<NodeId>,
Expand Down
43 changes: 2 additions & 41 deletions base_layer/wallet_ffi/wallet.h
Original file line number Diff line number Diff line change
Expand Up @@ -85,12 +85,8 @@ struct FeePerGramStat;

struct FeePerGramStatsResponse;

struct FixedHash;

struct InboundTransaction;

struct Option_NodeId;

struct OutboundTransaction;

/**
Expand Down Expand Up @@ -159,6 +155,8 @@ struct RistrettoSecretKey;

struct TariAddress;

struct TariBaseNodeState;

struct TariCompletedTransactions;

struct TariContacts;
Expand Down Expand Up @@ -324,43 +322,6 @@ typedef struct P2pConfig TariCommsConfig;

typedef struct Balance TariBalance;

typedef struct FixedHash BlockHash;

struct TariBaseNodeState {
/**
* The ID of the base node this wallet is connected to
*/
struct Option_NodeId node_id;
/**
* The current chain height, or the block number of the longest valid chain, or zero if there is no chain
*/
uint64_t height_of_longest_chain;
/**
* The block hash of the current tip of the longest valid chain
*/
BlockHash best_block;
/**
* Timestamp of the tip block in the longest valid chain
*/
uint64_t best_block_timestamp;
/**
* The configured number of blocks back from the tip that this database tracks. A value of 0 indicates that
* pruning mode is disabled and the node will keep full blocks from the time it was set. If pruning horizon
* was previously enabled, previously pruned blocks will remain pruned. If set from initial sync, full blocks
* are preserved from genesis (i.e. the database is in full archival mode).
*/
uint64_t pruning_horizon;
/**
* The height of the pruning horizon. This indicates from what height a full block can be provided
* (exclusive). If `pruned_height` is equal to the `height_of_longest_chain` no blocks can be
* provided. Archival nodes wil always have an `pruned_height` of zero.
*/
uint64_t pruned_height;
bool is_node_synced;
uint64_t updated_at;
uint64_t latency;
};

typedef struct FeePerGramStatsResponse TariFeePerGramStats;

typedef struct FeePerGramStat TariFeePerGramStat;
Expand Down

0 comments on commit b0d2032

Please sign in to comment.