LibC: Fix bad error check after open() in dlopen()
This commit is contained in:
parent
be5311be99
commit
d71bfb9614
Notes:
sideshowbarker
2024-07-18 22:42:14 +09:00
Author: https://github.com/awesomekling Commit: https://github.com/SerenityOS/serenity/commit/d71bfb96142
1 changed files with 1 additions and 1 deletions
|
@ -78,7 +78,7 @@ void* dlopen(const char* filename, int flags)
|
|||
}
|
||||
|
||||
int fd = open(filename, O_RDONLY);
|
||||
if (!fd) {
|
||||
if (fd < 0) {
|
||||
g_dlerror_msg = String::formatted("Unable to open file {}", filename);
|
||||
return nullptr;
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue