Skip to content

Commit 3392ba1

Browse files
committed
Return -1 from sparsebundle_open_file on failure
As per the expectation of the call sites. Returning errno is not necessary, as the caller can check errno directly.
1 parent c5dfc45 commit 3392ba1

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/sparsebundlefs.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -222,7 +222,7 @@ static int sparsebundle_open_file(const char *path)
222222
return sparsebundle_open_file(path);
223223
}
224224
syslog(LOG_ERR, "failed to open %s: %s", path, strerror(errno));
225-
return -errno;
225+
return -1;
226226
}
227227

228228
sparsebundle->open_files[path] = fd;

0 commit comments

Comments
 (0)