
Why do we need to use a regexp against the storage pool path at all? Anything can be a valid path in Linux. Even if it has spaces, non-ASCII characters, etc. The only validation that seems useful to me is to check if the path exists (which I believe it's done by the backend). The current code is limiting which paths we can use as storage pool in Kimchi, when they're perfectly fine with libvirt. I just created a local storage pool with the path "/home/vianac/crístian viana" (notice the space and the non-ASCII character) using virsh and it worked just fine. Am 12-02-2014 12:03, schrieb Pradeep K Surisetty:
Defining a New DIR based Storage Pool fails, if user appends "/" to path. For ex: If user use "/home/user/vms/" instead of "/home/user/vms", it fails with " Not a valid linux path"
Issue: https://github.com/kimchi-project/kimchi/issues/316
Signed-off-by: Chandan Kumar<psuriset@linux.vnet.ibm.com> Reviewed-by: Pradeep K Surisetty <psuriset@linux.vnet.ibm.com>