• mkwt@lemmy.world
    link
    fedilink
    arrow-up
    88
    arrow-down
    1
    ·
    19 hours ago

    Windows does, in fact, have signals. They’re just not all the same as Unix signals, and the behavior is different. Here’s a write-up.

    You’re correct there is no “please terminate but you don’t have to” signal in Windows. Windowless processes sometimes make up their own nonstandard events to implement the functionality. As you mentioned, windowed processes have WM_CLOSE.

    Memory access violations (akin to SIGSEGV), and other system exceptions can be handled through Structured Exception Handling.

    • Scoopta@programming.dev
      link
      fedilink
      arrow-up
      11
      ·
      19 hours ago

      TIL about the console signaling stuff, good to know. I am aware of SEH but that seemed a little too in the weeds for this discussion since that’s as you say akin to SIGSEGV

      • marcos@lemmy.world
        link
        fedilink
        arrow-up
        13
        ·
        18 hours ago

        The NT kernel was all built to emulate object orientation (read Smalltalk, not C++) style message passing. That’s because it was the 90s, and it’s the new technology kernel.

        So yeah, expect everything to have more flexibility sending data around, and no standardization at all so you can’t have any generic functionality.