Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Do not assume file must exist after an open call #789

Merged
merged 1 commit into from
Jul 31, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions client/src/unifyfs_fid.c
Original file line number Diff line number Diff line change
Expand Up @@ -553,15 +553,15 @@ int unifyfs_fid_open(
}
}

/* File should exist at this point,
* update our cache with its metadata. */
/* Update our cache with its metadata. */
ret = unifyfs_fid_fetch(client, path);
if (ret != UNIFYFS_SUCCESS) {
/* Failed to get metadata for a file that should exist.
* Perhaps it was since deleted. We could try to create
* it again and loop through these steps, but for now
* consider this situation to be an error. */
LOGERR("Failed to get metadata on existing file %s", path);
/* Failed to get metadata.
* Perhaps it was opened without O_CREAT or it
* was since deleted. For the latter, we could
* try to create it again and loop through these
* steps. */
LOGDBG("Failed to get metadata on file %s", path);
return ret;
}

Expand Down
Loading