Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

unix: document unsafety for std sig{action,altstack} #127843

Merged

Commits on Jul 18, 2024

  1. unix: Unsafe-wrap stack_overflow::signal_handler

    sometimes a safety comment is a prayer.
    avoid fuzzy provenance casts after deref.
    
    Co-authored-by: Jonas Böttiger <[email protected]>
    workingjubilee and joboet committed Jul 18, 2024
    Configuration menu
    Copy the full SHA
    9e354da View commit details
    Browse the repository at this point in the history
  2. unix: lift init of sigaltstack before sigaction

    This is technically "not necessary", as we will "just" segfault instead
    if we e.g. arrive inside the handler fn with the null altstack. However,
    it seems incorrect to go about this hoping that segfaulting is okay,
    seeing as how our purpose here is to mitigate stack overflow problems.
    
    Make sure NEED_ALTSTACK syncs with PAGE_SIZE when we do.
    
    Co-authored-by: Jonas Böttiger <[email protected]>
    workingjubilee and joboet committed Jul 18, 2024
    Configuration menu
    Copy the full SHA
    357ba1f View commit details
    Browse the repository at this point in the history
  3. unix: Unsafe-wrap stack_overflow::cleanup

    Editorialize on the wisdom of this as we do.
    workingjubilee committed Jul 18, 2024
    Configuration menu
    Copy the full SHA
    fa628ce View commit details
    Browse the repository at this point in the history
  4. unix: Unsafe-wrap stack_overflow::{drop,make}_handler

    Note that current_guard is probably not unsafe for future work.
    workingjubilee committed Jul 18, 2024
    Configuration menu
    Copy the full SHA
    c1740ee View commit details
    Browse the repository at this point in the history
  5. unix: acquire-load NEED_ALTSTACK

    Co-authored-by: Jonas Böttiger <[email protected]>
    workingjubilee and joboet authored Jul 18, 2024
    Configuration menu
    Copy the full SHA
    529fcbc View commit details
    Browse the repository at this point in the history