Earlier quoted context omitted.
The irc client irssi has something like this in /upgrade where it spawns a new binary but passing along active socket connections and their associated irc room states, I believe
WeeChat definitely does this. I don't know whether irssi supports it as well. Too bad WeeChat can't keep TLS connections open on /upgrade though
its not that hard to do if the program is made for this, even in C, its pretty hard to add when it isnt tho since you need a compat. layer.
Sometimes the new program simply has import functions for the old memory layout.