fixed problem with full path-file-name.
This commit is contained in:
parent
ad082a8cb2
commit
30708ff4bc
@ -929,13 +929,20 @@ int main(int argc, char *argv[])
|
||||
}
|
||||
|
||||
bool found_fln = false;
|
||||
// 1st check if the file name is found in the current directory
|
||||
string pathFln("");
|
||||
pathFln = "./" + fileName;
|
||||
// 1st check if the file name is the full path-file name and the file exists
|
||||
pathFln = fileName;
|
||||
if (dump_file_exists(pathFln))
|
||||
found_fln = true;
|
||||
|
||||
// 2nd check if file name is found in any default search paths if not already found in the current directory
|
||||
// 2nd check if the file name is found in the current directory
|
||||
if (!found_fln) {
|
||||
pathFln = "./" + fileName;
|
||||
if (dump_file_exists(pathFln))
|
||||
found_fln = true;
|
||||
}
|
||||
|
||||
// 3rd check if file name is found in any default search paths if not already found in the current directory
|
||||
if (!found_fln) {
|
||||
PStringVector pathList = startupHandler->GetDataPathList();
|
||||
for (unsigned int i=0; i<pathList.size(); i++) {
|
||||
|
@ -2388,6 +2388,7 @@ void PTextEdit::musrDump()
|
||||
QVector<QString> cmd;
|
||||
QString str = fAdmin->getExecPath() + "/dump_header";
|
||||
cmd.append(str);
|
||||
cmd.append("-fn");
|
||||
cmd.append(fileName);
|
||||
|
||||
PDumpOutputHandler dumpOutputHandler(cmd);
|
||||
|
@ -2488,6 +2488,7 @@ void PTextEdit::musrDump()
|
||||
QVector<QString> cmd;
|
||||
QString str = fAdmin->getExecPath() + "/dump_header";
|
||||
cmd.append(str);
|
||||
cmd.append("-fn");
|
||||
cmd.append(fileName);
|
||||
|
||||
PDumpOutputHandler dumpOutputHandler(cmd);
|
||||
|
Loading…
x
Reference in New Issue
Block a user