Fixed IllegalSyntaxException when using spaces in path #11782

Change-Id: I105b2835d44c94f00b847f342fd0a6e0ef571e97