mergetool: check return value from read