Skip to content

Commit

Permalink
Use ld-compatible symbol in ic-cdk-timers (#503)
Browse files Browse the repository at this point in the history
  • Loading branch information
adamspofford-dfinity authored Jul 24, 2024
1 parent 5ae0552 commit 5979571
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion src/ic-cdk-timers/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -260,7 +260,14 @@ fn update_ic0_timer() {
});
}

#[export_name = "canister_update <ic-cdk internal> timer_executor"]
#[cfg_attr(
target_family = "wasm",
export_name = "canister_update <ic-cdk internal> timer_executor"
)]
#[cfg_attr(
not(target_family = "wasm"),
export_name = "canister_update_ic_cdk_internal.timer_executor"
)]
extern "C" fn timer_executor() {
if ic_cdk::api::caller() != ic_cdk::api::id() {
ic_cdk::trap("This function is internal to ic-cdk and should not be called externally.");
Expand Down

0 comments on commit 5979571

Please sign in to comment.