Skip to content

Commit

Permalink
redo the fix from before on config lock
Browse files Browse the repository at this point in the history
I had removed this for kh19 but caused a problem but that was because another
part was missing.  Essentially the config lock should of been taken earlier.
It was leaving read locks on the config which prevented a reload from doing the
switchover.
  • Loading branch information
karlheyes committed Mar 7, 2023
1 parent 86e9970 commit c7a2333
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/fserve.c
Original file line number Diff line number Diff line change
Expand Up @@ -372,7 +372,6 @@ static fh_node *open_fh (fbinfo *finfo, mount_proxy *minfo)
// insert new one
if (fh->finfo.mount[0])
{
config_get_config();
char *fullpath= util_get_path_from_normalised_uri (fh->finfo.mount, fh->finfo.flags&FS_USE_ADMIN);
config_release_config ();

Expand Down Expand Up @@ -887,7 +886,7 @@ int fserve_setup_client_fb (client_t *client, fbinfo *finfo)
if ((finfo->flags & FS_MISSING) || ((finfo->flags & FS_FALLBACK) && finfo->limit == 0))
return -1;

minfo = config_lock_mount (NULL, finfo->mount);
minfo = config_lock_mount (config_get_config(), finfo->mount);
avl_tree_wlock (fh_cache);
fh = find_fh (finfo);

Expand Down

0 comments on commit c7a2333

Please sign in to comment.