Check whether path is valid before accessing it
Check whether path is valid before accessing it

Reviewed-by: ultrotter


ganeti-github-testing/ganeti-test-1,leshchevds/ganeti,onponomarev/ganeti,mbakke/ganeti,apyrgio/snf-ganeti,yiannist/ganeti,yiannist/ganeti,grnet/snf-ganeti,bitemyapp/ganeti,andir/ganeti,ganeti-github-testing/ganeti-test-1,bitemyapp/ganeti,ganeti/ganeti,dimara/ganeti,dimara/ganeti,apyrgio/ganeti,grnet/snf-ganeti,andir/ganeti,yiannist/ganeti,ganeti/ganeti,mbakke/ganeti,ganeti/ganeti,leshchevds/ganeti,mbakke/ganeti,leshchevds/ganeti,andir/ganeti,onponomarev/ganeti,apyrgio/ganeti,apyrgio/snf-ganeti