diff options
author | Luke Leighton <lkcl@samba.org> | 2000-04-22 09:15:53 +0000 |
---|---|---|
committer | Luke Leighton <lkcl@samba.org> | 2000-04-22 09:15:53 +0000 |
commit | ea771b5c7a43cb0746f1c7f975f69abb056db54e (patch) | |
tree | bbedcb84564a83cef608f790579c5ba76b17b55f /source/smbd/trans2.c | |
parent | 0df2063902660b059590eeb27d2f994e4d16af44 (diff) | |
download | samba-ea771b5c7a43cb0746f1c7f975f69abb056db54e.tar.gz samba-ea771b5c7a43cb0746f1c7f975f69abb056db54e.tar.xz samba-ea771b5c7a43cb0746f1c7f975f69abb056db54e.zip |
merge from last 2 days (not compiled).
Diffstat (limited to 'source/smbd/trans2.c')
-rw-r--r-- | source/smbd/trans2.c | 13 |
1 files changed, 2 insertions, 11 deletions
diff --git a/source/smbd/trans2.c b/source/smbd/trans2.c index 2ca06ab7464..94fed3884d8 100644 --- a/source/smbd/trans2.c +++ b/source/smbd/trans2.c @@ -221,10 +221,6 @@ static int call_trans2open(connection_struct *conn, char *inbuf, char *outbuf, unix_convert(fname,conn,0,&bad_path,NULL); - fsp = file_new(); - if (!fsp) - return(ERROR(ERRSRV,ERRnofids)); - if (!check_name(fname,conn)) { if((errno == ENOENT) && bad_path) @@ -232,23 +228,21 @@ static int call_trans2open(connection_struct *conn, char *inbuf, char *outbuf, unix_ERR_class = ERRDOS; unix_ERR_code = ERRbadpath; } - file_free(fsp); return(UNIXERROR(ERRDOS,ERRnoaccess)); } unixmode = unix_mode(conn,open_attr | aARCH, fname); - open_file_shared(fsp,conn,fname,open_mode,open_ofun,unixmode, + fsp = open_file_shared(conn,fname,open_mode,open_ofun,unixmode, oplock_request, &rmode,&smb_action); - if (!fsp->open) + if (!fsp) { if((errno == ENOENT) && bad_path) { unix_ERR_class = ERRDOS; unix_ERR_code = ERRbadpath; } - file_free(fsp); return(UNIXERROR(ERRDOS,ERRnoaccess)); } @@ -1794,8 +1788,6 @@ static int call_trans2setfilepathinfo(connection_struct *conn, * the share mode contained ALLOW_SHARE_DELETE */ - if(lp_share_modes(SNUM(conn))) - { if(!GET_ALLOW_SHARE_DELETE(fsp->share_mode)) return(ERROR(ERRDOS,ERRnoaccess)); @@ -1900,7 +1892,6 @@ dev = %x, inode = %.0f\n", iterate_fsp->fnum, (unsigned int)dev, (double)inode)) delete_on_close ? "Added" : "Removed", fsp->fnum, fsp->fsp_name )); } /* end if(delete_on_close && !GET_DELETE_ON_CLOSE_FLAG(fsp->share_mode)) */ - } /* end if lp_share_modes() */ } /* end if is_directory. */ } else return(ERROR(ERRDOS,ERRunknownlevel)); |