EldoS | Feel safer!

Software components for data protection, secure storage and transfer

Terminating process with pending callbacks

Also by EldoS: SecureBlackbox
200+ components and classes for digital security, signing, encryption and secure networking.
#12005
Posted: 12/29/2009 19:54:32
by Weihan Wang (Standard support level)
Joined: 12/13/2009
Posts: 4

What would happen if the process terminates (e.g. due to crashes) with ongoing callback operations? Does CBFS return immediately to the caller with an error code?

Thanks
#12007
Posted: 12/30/2009 01:55:23
by Volodymyr Zinin (EldoS Corp.)

If it terminates a process which contains the CallbackFS callbacks then nothing will be called already (the process is just terminated and all resources allocated for it are cleaned).

If another process accessed a CallbackFS virtual disk but before its terminating has not closed any file handles on it then Windows itself closes them and the OnClose callback will be called. If there are pending callback operations at this time then CallbackFS will wait for them and process in the same way as the "standard" file system (FATFS, NTFS) do.
#12080
Posted: 01/10/2010 09:02:03
by Weihan Wang (Standard support level)
Joined: 12/13/2009
Posts: 4

My last post was confusing. What I meant is the following scenario:

Process A contains CallbackFS callbacks. Process B is now accessing the CallbackFS virtual disk which causes an ongoing callback operation within process A. Now, before this operation returns, A crashes. My questions is, in this case, will the system call that blocks B returns immediately with an error code, or will the system call block until timeout (specified by A via CallbackFileSystem.ResetTimeout), or ...?
#12081
Posted: 01/10/2010 09:22:45
by Eugene Mayevski (EldoS Corp.)

The driver will wait until timeout elapses and then return control to the OS with the error.


Sincerely yours
Eugene Mayevski
#12084
Posted: 01/11/2010 01:18:05
by Eugene Mayevski (EldoS Corp.)

Correction: if the driver can detect process A shutdown (i.e. when the process A is terminated, and not suspended to capture debug information or blocked), execution will be returned immediately.


Sincerely yours
Eugene Mayevski
Also by EldoS: CallbackProcess
A component to control process creation and termination in Windows and .NET applications.

Reply

Statistics

Topic viewed 2317 times

Number of guests: 1, registered members: 0, in total hidden: 0




|

Back to top

As of July 15, 2016 EldoS Corporation will operate as a division of /n software inc. For more information, please read the announcement.

Got it!