• Trailblazing Braille Taser@lemmy.dbzer0.com
    link
    fedilink
    arrow-up
    12
    ·
    edit-2
    10 months ago

    I’m terrified by this binary config file. Why?! Was he writing C and said “fuck it, memcpy”?

    Edit: I suppose it would be more like “fuck it, fprintf(f, (char*)my_config_object, sizeof(my_config_object))”

    • Troy@lemmy.ca
      link
      fedilink
      arrow-up
      2
      arrow-down
      1
      ·
      10 months ago

      I mean, python has pickle and people use that to store config. It’s a weird practice, and totally unsafe, but it works well enough. This wouldn’t be that different.