Merge "Avoid crashing when a directory does not exist" into pi-dev
am: 4eec17a873

Change-Id: I2a2cd91ea12f632ffbdbb33ffff57db5a948506b