mirror of
https://github.com/samba-team/samba.git
synced 2025-01-12 09:18:10 +03:00
r22882: It seems entirly reasonable to follow metze's suggestion and check for
a valid file handle first. Andrew Bartlett
This commit is contained in:
parent
42f6c5106e
commit
3947db3dcb
@ -610,14 +610,13 @@ static NTSTATUS ipc_qfileinfo(struct ntvfs_module_context *ntvfs,
|
|||||||
struct ntvfs_request *req, union smb_fileinfo *info)
|
struct ntvfs_request *req, union smb_fileinfo *info)
|
||||||
{
|
{
|
||||||
struct ipc_private *private = ntvfs->private_data;
|
struct ipc_private *private = ntvfs->private_data;
|
||||||
switch (info->generic.level) {
|
struct pipe_state *p = pipe_state_find(private, info->generic.in.file.ntvfs);
|
||||||
case RAW_FILEINFO_GENERIC:
|
|
||||||
{
|
|
||||||
struct pipe_state *p;
|
|
||||||
p = pipe_state_find(private, info->generic.in.file.ntvfs);
|
|
||||||
if (!p) {
|
if (!p) {
|
||||||
return NT_STATUS_INVALID_HANDLE;
|
return NT_STATUS_INVALID_HANDLE;
|
||||||
}
|
}
|
||||||
|
switch (info->generic.level) {
|
||||||
|
case RAW_FILEINFO_GENERIC:
|
||||||
|
{
|
||||||
ZERO_STRUCT(info->generic.out);
|
ZERO_STRUCT(info->generic.out);
|
||||||
info->generic.out.attrib = FILE_ATTRIBUTE_NORMAL;
|
info->generic.out.attrib = FILE_ATTRIBUTE_NORMAL;
|
||||||
info->generic.out.fname.s = strrchr(p->pipe_name, '\\');
|
info->generic.out.fname.s = strrchr(p->pipe_name, '\\');
|
||||||
|
Loading…
Reference in New Issue
Block a user