[CRIU] Re: [PATCH] parasite: Refactor code to follow calling convention

Cyrill Gorcunov gorcunov at openvz.org
Fri Mar 16 10:35:56 EDT 2012


On Fri, Mar 16, 2012 at 06:31:43PM +0400, Pavel Emelyanov wrote:
> 
> After a bit more thinking. We now have 3 return values:
> 
> 1. line where an error occurred
> 2. some abstract ret on status
> 3. the return code from call
> 
> The 1st one can be eliminated by simply emitting a log message. We couldn't
> do it before and now we can.
> 
> The 2nd one used to be the errno from the syscall, but yet again -- we
> can write it into log now and thus don't really need.
> 
> The return code can now only denote whether an operation succeeded or not.
> 
> That said, we don't need the whole parasite_status_t at all now. Do we?
> 

Yes, this status came from early times when we had no logger at all.
Indeed we can simply drop all this (but note I'll have to add some
converter from long to number as we have in restorer, because parasite
has no ability to use printf and such). But anyway, seems dropping
status is a win here. Thanks!

	Cyrill


More information about the CRIU mailing list