Fix deadlock when open fails
Add missing break statement and initialize mFilePath variable
Refactor setupBook, true means operation was successful