[CRIU] [PATCH 05/16] restore: don't add unneeded vma with zero start and end addresses

Pavel Emelyanov xemul at parallels.com
Tue Nov 20 09:24:03 EST 2012


On 11/20/2012 06:18 PM, Andrew Vagin wrote:
> On Tue, Nov 20, 2012 at 06:00:18PM +0400, Pavel Emelyanov wrote:
>> On 11/14/2012 09:19 PM, Andrey Vagin wrote:
>>
>>> Signed-off-by: Andrey Vagin <avagin at openvz.org>
>>> ---
>>>  cr-restore.c | 5 +++--
>>>  1 file changed, 3 insertions(+), 2 deletions(-)
>>>
>>> diff --git a/cr-restore.c b/cr-restore.c
>>> index 1dfe833..276cf49 100644
>>> --- a/cr-restore.c
>>> +++ b/cr-restore.c
>>> @@ -194,12 +194,13 @@ static int read_vmas(int pid, struct list_head *vmas, int *nr_vmas)
>>>  		if (!vma)
>>>  			break;
>>>  
>>> -		(*nr_vmas)++;
>>> -		list_add_tail(&vma->list, vmas);
>>>  		ret = pb_read_one_eof(fd, &e, PB_VMAS);
>>>  		if (ret <= 0)
>>>  			break;
>>>  
>>> +		(*nr_vmas)++;
>>> +		list_add_tail(&vma->list, vmas);
>>> +
>>
>> This breaks git-bisect-ness, doesn't it?
> 
> No, it doesn't. This patch fixes a bug in crtools. I check, that all
> tests passed after it.

Plz, describe th ebug.

>>
>>>  		if (e->fd != -1) {
>>>  			ret = -1;
>>>  			pr_err("Error in vma->fd setting (%Ld)\n",
>>>
>>
>>
> .
> 




More information about the CRIU mailing list