Pull 37 redux

Fixed issue where pexpect would attempt to execute a directory because it has the 'execute' bit set.