Skip to content
Snippets Groups Projects

daemon: use __attribute__((constructor)) for protolayer_globals

Merged Oto Šťáva requested to merge protolayer-constructors into master

The protolayer_globals array can basically be treated as a constant by most of the program and its initialization only uses compile-time-known values. We basically only initialize parts of the array in different files throughout the codebase to maintain separation of concerns, so that each piece of Knot Resolver initializes the part that pertains to it. Therefore, I believe that it is more ergonomic to just use __attribute__((constructor)) for these functions, so as not to pollute daemon/main.c with these calls.

Merge request reports

Pipeline #126827 waiting for manual action

Pipeline: Knot Resolver

#126828

    Pipeline waiting for manual action for ead0fed0 on protolayer-constructors

    Approved by

    Merged by Oto ŠťávaOto Šťáva 9 months ago (Jun 20, 2024 8:36am UTC)

    Merge details

    • Changes merged into master with 4c9decf4.
    • Deleted the source branch.

    Pipeline #127330 failed

    Pipeline failed for 4c9decf4 on master

    Deployed to docs-deve‎lop/master‎ 9 months ago

    Activity

    Filter activity
    • Approvals
    • Assignees & reviewers
    • Comments (from bots)
    • Comments (from users)
    • Commits & branches
    • Edits
    • Labels
    • Lock status
    • Mentions
    • Merge request status
    • Tracking
    Please register or sign in to reply
    Loading