Skip to content
Open
Show file tree
Hide file tree
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
1 change: 1 addition & 0 deletions src/XrdXrootd/XrdXrootdConfig.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1685,6 +1685,7 @@ int XrdXrootdProtocol::xred(XrdOucStream &Config)
{"locate", RD_locate},
{"mkdir", RD_mkdir},
{"mv", RD_mv},
{"openw", RD_openw},
{"prepare", RD_prepare},
{"prepstage",RD_prepstg},
{"rm", RD_rm},
Expand Down
3 changes: 2 additions & 1 deletion src/XrdXrootd/XrdXrootdProtocol.hh
Original file line number Diff line number Diff line change
Expand Up @@ -241,7 +241,8 @@ private:
enum RD_func {RD_chmod = 0, RD_chksum, RD_dirlist, RD_locate, RD_mkdir,
RD_mv, RD_prepare, RD_prepstg, RD_rm, RD_rmdir,
RD_stat, RD_trunc, RD_ovld, RD_client,
RD_open1, RD_open2, RD_open3, RD_open4, RD_Num};
RD_openw, RD_open1, RD_open2, RD_open3, RD_open4,
RD_Num};

int do_Auth();
int do_Bind();
Expand Down
21 changes: 14 additions & 7 deletions src/XrdXrootd/XrdXrootdXeq.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1459,15 +1459,22 @@ int XrdXrootdProtocol::do_Open()
//
doDig = (digFS && SFS_LCLPATH(fn));

// Validate the path and then check if static redirection applies
// Validate the path/req type and then check if static redirection applies
//
if (doDig) {popt = XROOTDXP_NOLK; opC = 0;}
else {int ropt;
if (!(popt = Squash(fn))) return vpEmsg("Opening", fn);
if (Route[RD_open1].Host[rdType] && (ropt = RPList.Validate(fn)))
return Response.Send(kXR_redirect, Route[ropt].Port[rdType],
Route[ropt].Host[rdType]);
}
else {int ropt = -1;
if (!(popt = Squash(fn))) return vpEmsg("Opening", fn);
if (Route[RD_open1].Host[rdType])
ropt = RPList.Validate(fn);
else
if (Route[RD_openw].Host[rdType] && ('w' == usage || strchr(op, 'd')))
ropt = RD_openw;
if (ropt > 0)
return Response.Send(
kXR_redirect, Route[ropt].Port[rdType],
Route[ropt].Host[rdType]
);
}

// Add the multi-write option if this path supports it
//
Expand Down
Loading