From 6209570e349a31e333968c4fdb20e8e56593e0de Mon Sep 17 00:00:00 2001 From: Augustin Cavalier Date: Tue, 19 Oct 2021 11:34:32 -0400 Subject: [PATCH] Replace usages of B_FILE_NOT_FOUND in public-facing APIs. As BeOS R5 had deprecated this error code, this should in theory not cause any particular problems. --- src/kits/midi/SoftSynth.cpp | 2 +- src/system/runtime_loader/elf_versioning.cpp | 2 +- src/tests/kits/storage/EntryTest.cpp | 1 - src/tools/cppunit/TestUtils.cpp | 4 ---- 4 files changed, 2 insertions(+), 7 deletions(-) diff --git a/src/kits/midi/SoftSynth.cpp b/src/kits/midi/SoftSynth.cpp index a7c003cc4b..b18b0a6978 100644 --- a/src/kits/midi/SoftSynth.cpp +++ b/src/kits/midi/SoftSynth.cpp @@ -168,7 +168,7 @@ BSoftSynth::SetInstrumentsFile(const char* path) return B_BAD_VALUE; if (!BEntry(path).Exists()) - return B_FILE_NOT_FOUND; + return B_ENTRY_NOT_FOUND; if (IsLoaded()) Unload(); diff --git a/src/system/runtime_loader/elf_versioning.cpp b/src/system/runtime_loader/elf_versioning.cpp index 46f095e0e3..950b8017fb 100644 --- a/src/system/runtime_loader/elf_versioning.cpp +++ b/src/system/runtime_loader/elf_versioning.cpp @@ -181,7 +181,7 @@ check_needed_image_versions(image_t* image) // the file should also appear in DT_NEEDED. FATAL("%s: Version dependency \"%s\" not found", image->path, fileName); - return B_FILE_NOT_FOUND; + return B_ENTRY_NOT_FOUND; } elf_vernaux* vernaux diff --git a/src/tests/kits/storage/EntryTest.cpp b/src/tests/kits/storage/EntryTest.cpp index 0e0220f243..b8a20afa51 100644 --- a/src/tests/kits/storage/EntryTest.cpp +++ b/src/tests/kits/storage/EntryTest.cpp @@ -143,7 +143,6 @@ static const status_t kErrors[] = { B_ERROR, B_FILE_ERROR, B_FILE_EXISTS, - B_FILE_NOT_FOUND, B_IS_A_DIRECTORY, B_LINK_LIMIT, B_NAME_TOO_LONG, diff --git a/src/tools/cppunit/TestUtils.cpp b/src/tools/cppunit/TestUtils.cpp index 524718e379..9c354ff38c 100644 --- a/src/tools/cppunit/TestUtils.cpp +++ b/src/tools/cppunit/TestUtils.cpp @@ -35,10 +35,6 @@ status_t DecodeResult(status_t result) { str = "B_FILE_ERROR"; break; - case B_FILE_NOT_FOUND: - str = "B_FILE_NOT_FOUND"; - break; - case B_FILE_EXISTS: str = "B_FILE_EXISTS"; break;