diff options
Diffstat (limited to 'odb/odb.cxx')
-rw-r--r-- | odb/odb.cxx | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/odb/odb.cxx b/odb/odb.cxx index 9491252..dcddf96 100644 --- a/odb/odb.cxx +++ b/odb/odb.cxx @@ -252,6 +252,7 @@ main (int argc, char* argv[]) // if (file.relative ()) { + bool found (false); path dd (driver_path (path (argv[0])).directory ()); for (path d (dd);; d = d.directory ()) @@ -263,6 +264,7 @@ main (int argc, char* argv[]) if (stat (f.string ().c_str (), &s) == 0 && S_ISREG (s.st_mode)) { file = f; + found = true; break; } @@ -270,8 +272,8 @@ main (int argc, char* argv[]) break; } - if (file.relative ()) - file = dd / file; + if (!found) + file = dd / file; // For diagnostics. } int ac (3); |