Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to hibernate application?

my question may seem too weird but i thought about the windows hibernation thing and i was wondering if there is a way to hibernate a specific process or application. i.e : when windows start up from a normal shutdown/restart it will load all startup programs normally but in addition of that it will load a specific program with it`s previous status before shutting down the computer.

I have though about reserving the memory location and retrieve it back when computer start up , but is there any application that does that in windows environment ?

like image 639
R.Vector Avatar asked Aug 31 '25 04:08

R.Vector


1 Answers

That cannot work. The state of a process is almost never contained in just the process itself. A gui app creates user32 and gdi objects that are stored in a heap associated with the desktop. It makes calls to Windows that affect the window manager state. It makes I/O calls that cause code inside drivers to run. Which in turn affects allocations inside the kernel pools. Multiply the trouble by every pipe or rpc channel it opens to talk to other processes. And shared resources like the clipboard.

Only making a snapshot of the entire operating system state works.

like image 189
Hans Passant Avatar answered Sep 02 '25 19:09

Hans Passant