image: don't free an img object from pb_write_one()
image: don't free an img object from pb_write_one()

This is unexpected behaviour.
pb_write_one
  open_image_lazy
    do_open_image
      xfree(img)

255             if (pb_write_one(img, &cpu_info, PB_CPUINFO) < 0) {
>>> >>>     CID 92728:  Memory - illegal accesses  (USE_AFTER_FREE)
>>> >>>     Calling "close_image" dereferences freed pointer "img".
256                     close_image(img);
257                     return -1;
258             }

Signed-off-by: Andrey Vagin <74c05afa918858348d6db8037d82fa8124870113@openvz.org>
Signed-off-by: Pavel Emelyanov <c9a32589e048e044184536f7ac71ef92fe82df3e@parallels.com>

biddyweb/criu,ldu4/criu,svloyso/criu,LK4D4/criu,AuthenticEshkinKot/criu,ldu4/criu,gablg1/criu,marcosnils/criu,sdgdsffdsfff/criu,marcosnils/criu,svloyso/criu,fbocharov/criu,tych0/criu,eabatalov/criu,efiop/criu,gonkulator/criu,sdgdsffdsfff/criu,AuthenticEshkinKot/criu,AuthenticEshkinKot/criu,AuthenticEshkinKot/criu,sdgdsffdsfff/criu,eabatalov/criu,biddyweb/criu,KKoukiou/criu-remote,tych0/criu,KKoukiou/criu-remote,fbocharov/criu,LK4D4/criu,tych0/criu,tych0/criu,biddyweb/criu,svloyso/criu,gablg1/criu,tych0/criu,eabatalov/criu,efiop/criu,KKoukiou/criu-remote,biddyweb/criu,gablg1/criu,gonkulator/criu,biddyweb/criu,fbocharov/criu,AuthenticEshkinKot/criu,gablg1/criu,rentzsch/criu,gonkulator/criu,marcosnils/criu,KKoukiou/criu-remote,efiop/criu,marcosnils/criu,marcosnils/criu,rentzsch/criu,rentzsch/criu,AuthenticEshkinKot/criu,KKoukiou/criu-remote,ldu4/criu,eabatalov/criu,gonkulator/criu,rentzsch/criu,wtf42/criu,wtf42/criu,gonkulator/criu,wtf42/criu,rentzsch/criu,gonkulator/criu,KKoukiou/criu-remote,svloyso/criu,efiop/criu,wtf42/criu,gablg1/criu,wtf42/criu,marcosnils/criu,tych0/criu,LK4D4/criu,fbocharov/criu,efiop/criu,ldu4/criu,svloyso/criu,efiop/criu,fbocharov/criu,sdgdsffdsfff/criu,gablg1/criu,ldu4/criu,rentzsch/criu,wtf42/criu,eabatalov/criu,biddyweb/criu,fbocharov/criu,svloyso/criu,LK4D4/criu,ldu4/criu,LK4D4/criu,LK4D4/criu,sdgdsffdsfff/criu,eabatalov/criu,sdgdsffdsfff/criu