diff options
author | Volker Lendecke <vlendec@samba.org> | 2007-07-30 10:30:19 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 12:29:03 -0500 |
commit | ef97e2dece55d84e64bdcbb922939ea28199a2e6 (patch) | |
tree | dc157d578da52c4978211024cec442f5fd8d87da /source3/smbd/reply.c | |
parent | 4392d47b34720d2dcd8ee47bd14a71bf1eab2c86 (diff) | |
download | samba-ef97e2dece55d84e64bdcbb922939ea28199a2e6.tar.gz samba-ef97e2dece55d84e64bdcbb922939ea28199a2e6.tar.bz2 samba-ef97e2dece55d84e64bdcbb922939ea28199a2e6.zip |
r24079: Convert reply_dskattr to the new API
(This used to be commit c8e0aa5752fde34f7271a4fad758dfae0991722d)
Diffstat (limited to 'source3/smbd/reply.c')
-rw-r--r-- | source3/smbd/reply.c | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/source3/smbd/reply.c b/source3/smbd/reply.c index 7af0807c0a..13f1c1ce58 100644 --- a/source3/smbd/reply.c +++ b/source3/smbd/reply.c @@ -1007,18 +1007,18 @@ int reply_setatr(connection_struct *conn, char *inbuf,char *outbuf, int dum_size Reply to a dskattr. ****************************************************************************/ -int reply_dskattr(connection_struct *conn, char *inbuf,char *outbuf, int dum_size, int dum_buffsize) +void reply_dskattr(connection_struct *conn, struct smb_request *req) { - int outsize = 0; SMB_BIG_UINT dfree,dsize,bsize; START_PROFILE(SMBdskattr); if (get_dfree_info(conn,".",True,&bsize,&dfree,&dsize) == (SMB_BIG_UINT)-1) { + reply_unixerror(req, ERRHRD, ERRgeneral); END_PROFILE(SMBdskattr); - return(UNIXERROR(ERRHRD,ERRgeneral)); + return; } - - outsize = set_message(inbuf,outbuf,5,0,True); + + reply_outbuf(req, 5, 0); if (Protocol <= PROTOCOL_LANMAN2) { double total_space, free_space; @@ -1037,21 +1037,21 @@ int reply_dskattr(connection_struct *conn, char *inbuf,char *outbuf, int dum_siz if (dsize > 0xFFFF) dsize = 0xFFFF; if (dfree > 0xFFFF) dfree = 0xFFFF; - SSVAL(outbuf,smb_vwv0,dsize); - SSVAL(outbuf,smb_vwv1,64); /* this must be 64 for dos systems */ - SSVAL(outbuf,smb_vwv2,512); /* and this must be 512 */ - SSVAL(outbuf,smb_vwv3,dfree); + SSVAL(req->outbuf,smb_vwv0,dsize); + SSVAL(req->outbuf,smb_vwv1,64); /* this must be 64 for dos systems */ + SSVAL(req->outbuf,smb_vwv2,512); /* and this must be 512 */ + SSVAL(req->outbuf,smb_vwv3,dfree); } else { - SSVAL(outbuf,smb_vwv0,dsize); - SSVAL(outbuf,smb_vwv1,bsize/512); - SSVAL(outbuf,smb_vwv2,512); - SSVAL(outbuf,smb_vwv3,dfree); + SSVAL(req->outbuf,smb_vwv0,dsize); + SSVAL(req->outbuf,smb_vwv1,bsize/512); + SSVAL(req->outbuf,smb_vwv2,512); + SSVAL(req->outbuf,smb_vwv3,dfree); } DEBUG(3,("dskattr dfree=%d\n", (unsigned int)dfree)); END_PROFILE(SMBdskattr); - return(outsize); + return; } /**************************************************************************** |